Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix mach compilation again; fold_constant has to be the same section as crc16_t10dif_copy_pmull #226

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion crc/aarch64/crc16_t10dif_copy_pmull.S
Original file line number Diff line number Diff line change
Expand Up @@ -379,13 +379,14 @@ v_br1 .req v5
.size crc16_t10dif_copy_pmull, .-crc16_t10dif_copy_pmull
#endif

ASM_DEF_RODATA
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do you want them in the .text section now? They were in .rodata before. You show a cross build in the comments but cross build seems to work fine when this is in rodata like other constants.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It worked for gcc but did not work for (apple-)clang.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$ make -f Makefile.unx CC=arm64-apple-darwin-gcc AR=arm64-apple-darwin-ar arch=aarch64 host_cpu=aarch64 DEFINES="-fno-stack-check" lib programs/igzip -j8
mkdir -p bin
  ---> Building crc/aarch64/crc16_t10dif_pmull.S  aarch64 
  ---> Building crc/aarch64/crc16_t10dif_copy_pmull.S  aarch64 
crc/aarch64/crc16_t10dif_pmull.S:222:9: error: unknown AArch64 fixup kind!
        ldr q_fold_const, fold_constant
        ^
crc/aarch64/crc16_t10dif_copy_pmull.S:231:9: error: unknown AArch64 fixup kind!
        ldr q_fold_const, fold_constant
        ^
make: *** [bin/crc16_t10dif_pmull.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [bin/crc16_t10dif_copy_pmull.o] Error 1

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this has been confirmed by #226 (comment)

.align 4
fold_constant:
.word 0x87e70000
.word 0x00000000
.word 0x371d0000
.word 0x00000000

ASM_DEF_RODATA
.shuffle_mask_lanchor = . + 0
#ifndef __APPLE__
.type shuffle_mask, %object
Expand Down
3 changes: 2 additions & 1 deletion crc/aarch64/crc16_t10dif_pmull.S
Original file line number Diff line number Diff line change
Expand Up @@ -364,13 +364,14 @@ v_br1 .req v5
.size crc16_t10dif_pmull, .-crc16_t10dif_pmull
#endif

ASM_DEF_RODATA
.align 4
fold_constant:
.word 0x87e70000
.word 0x00000000
.word 0x371d0000
.word 0x00000000

ASM_DEF_RODATA
.shuffle_mask_lanchor = . + 0
#ifndef __APPLE__
.type shuffle_mask, %object
Expand Down
Loading