diff --git a/gas/read.c b/gas/read.c index 0b0b05803c0..1643c5cdcf1 100644 --- a/gas/read.c +++ b/gas/read.c @@ -2202,7 +2202,7 @@ s_fill (int ignore ATTRIBUTE_UNUSED) md_cons_align (1); #endif - get_known_segmented_expression (&rep_exp); + expression (&rep_exp); if (*input_line_pointer == ',') { input_line_pointer++; diff --git a/gas/testsuite/gas/all/fill-1.s b/gas/testsuite/gas/all/fill-1.s new file mode 100644 index 00000000000..92d495a7bc0 --- /dev/null +++ b/gas/testsuite/gas/all/fill-1.s @@ -0,0 +1,5 @@ + .text + .fill (2f-1f), 1, 0x90 +1: + nop +2: diff --git a/gas/testsuite/gas/all/gas.exp b/gas/testsuite/gas/all/gas.exp index 365cabc0a46..93e31dab4ac 100644 --- a/gas/testsuite/gas/all/gas.exp +++ b/gas/testsuite/gas/all/gas.exp @@ -486,3 +486,5 @@ run_dump_test "org-3" run_dump_test "org-4" run_dump_test "org-5" run_dump_test "org-6" + +gas_test "fill-1.s" "" "" "test .fill forward label references"