From f991f5ae56468b225b5df848b47b5173dedf8332 Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Sun, 19 Oct 2008 16:45:27 -0700 Subject: [PATCH] smartalign: use a "times" construct rather than %rep Use a "times" construct rather than "%rep" for higher performance. No need to preprocess the same line over and over for no good reason. Signed-off-by: H. Peter Anvin --- macros/smartalign.mac | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/macros/smartalign.mac b/macros/smartalign.mac index 4dc8fd5c..48c07de5 100644 --- a/macros/smartalign.mac +++ b/macros/smartalign.mac @@ -186,9 +186,8 @@ USE: smartalign times (((%1) - (($-$$) % (%1))) % (%1)) nop %$end: %else - %rep %$pad / __ALIGN_%[__BITS__]BIT_GROUP__ - db __ALIGN_%[__BITS__]BIT_%[__ALIGN_%[__BITS__]BIT_GROUP__]B__ - %endrep + times (%$pad / __ALIGN_%[__BITS__]BIT_GROUP__) \ + db __ALIGN_%[__BITS__]BIT_%[__ALIGN_%[__BITS__]BIT_GROUP__]B__ %assign %$pad %$pad % __ALIGN_%[__BITS__]BIT_GROUP__ %if %$pad > 0 db __ALIGN_%[__BITS__]BIT_%[%$pad]B__