Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2007-11

A patch for external assembler output

2 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Sergei Gorelkin

Hello,

I found and fixed at least four issues with MASM assembler output:

- garbage was being output sometimes instead of source lines when compiling with -al. This is because lastfileinfo and lastinfile were never initialized for MASM writer. This is true for TPPCMPWAssembler, too.
- long lines were not wrapped.
- constants of type ait_comp_64bit output incorrectly.
- at end of file, current segment was not closed.

Furthermore, I moved variables lastinfile, lastsectype, lastfileinfo and infile, which are common to all external assemblers, from global scope to TExternalAssembler members. This reduces duplication and ensures that they are properly initialized for all assemblers that may be added in the future.

The patch is attached. Hope it will be useful.

Regards,
Sergei

Reply by email

Peter Vreman
to Sergei Gorelkin
you wrote 18 lines
Hello, I found and fixed at least four issues with MASM assembler output: - garbage was being output sometimes instead of source lines when compiling with -al. This is because lastfileinfo and lastinfile were never initialized for MASM writer. This is true for TPPCMPWAssembler, too. - long lines were not wrapped. - constants of type ait_comp_64bit output incorrectly. - at end of file, current segment was not closed. Furthermore, I moved variables lastinfile, lastsectype, lastfileinfo and infile, which are common to all external assemblers, from global scope to TExternalAssembler members. This reduces duplication and ensures that they are properly initialized for all assemblers that may be added in the future. The patch is attached. Hope it will be useful.

Thanks, applied in r9331.

Peter

Reply by email