diff options
Diffstat (limited to 'gold/testsuite')
-rwxr-xr-x | gold/testsuite/script_test_3.sh | 14 | ||||
-rw-r--r-- | gold/testsuite/script_test_3.t | 2 |
2 files changed, 15 insertions, 1 deletions
diff --git a/gold/testsuite/script_test_3.sh b/gold/testsuite/script_test_3.sh index cddb69a..d114edd 100755 --- a/gold/testsuite/script_test_3.sh +++ b/gold/testsuite/script_test_3.sh @@ -85,4 +85,18 @@ if test "$section_size" != "$segment_size"; then exit 1 fi +# At least one PT_LOAD segment should have an alignment >= 0x100000. +found=no +for a in `grep LOAD script_test_3.stdout | sed -e 's/^.* 0x/0x/'`; do + script="BEGIN { if ($a >= 0x100000) { print \"true\" } else { print \"false\" } }" + x=`awk "$script" < /dev/null` + if test "$x" = "true"; then + found=yes + fi +done +if test "$found" = "no"; then + echo "no LOAD segment has required alignment" + exit 1 +fi + exit 0 diff --git a/gold/testsuite/script_test_3.t b/gold/testsuite/script_test_3.t index a6a655f..75d8130 100644 --- a/gold/testsuite/script_test_3.t +++ b/gold/testsuite/script_test_3.t @@ -35,7 +35,7 @@ SECTIONS .tdata : { *(.tdata*) } :data :tls .tbss : { *(.tbss*) } :data :tls . += 0x100000; - . = ALIGN(0x100); + . = ALIGN(0x100000); .bss : { *(.bss) } :bss } |