forked from ArtemioUrbina/huc
-
Notifications
You must be signed in to change notification settings - Fork 12
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
Add source-level-debugging .sym output for mesen2 to PCEAS and HuCC #55
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…eue but is ignored by the peephole optimizer. Change the peephole optimizer to preserve comments when removing instructions. Change the option that outputs C source into the output file to use this i-code while a function is being compiled so that peephole optimizations are no longer spoiled by the queue being flushed when a C source line is output. Cleanup the function comments in io.c a bit.
…he output file. Change HuCC to always output the C source as comments now that it doesn't mess up the peephole optimizer anymore. Change #asm initial output tabbing to conform with the compiler's other output.
…ten to the output ROM.
… the cases. This will allow the generated code to know what all of the case constant values are, and then customize the code to use a jump-table instead of comparisons ... at some point in the future! Change the C source-code information from a comment to a ".line" for PCEAS.
…y the bank of a label instead of the address of a label.
…t bank and address parameters instead of a __far pointer. The underlying asm functions themselves are not changed, just way that HuCC fills in the parameters.
… of split bank and address values instead of a __far pointer.
Destructively sort the symbol table before output. Add an initial work-in-progress version of a modified form of wla-dx's sym file source-level debugging output for use with mesen2. Change various symbol structure members from ints into unsigned chars to save a little bit of memory.
…base() and set_far_offset() library functions so that C developers can apply a 64KB offset to the new functions, just like they can with the old HuC __farptr functions.
…to HuCC's const_expr() parser that Uli added. Change HuCC to use the const_expr() parser for "case" values.
… emulator. This is controlled with the "-gC", "-gA", or '-gL' command line flags to choose whether to output source mappings to the C, ASM, or PCEAS-generated .LST files. The .LST file gives the most information, because you see the macro expansions, but the ASM version might be preferable to developers who don't macros much. The C version will map to C source lines when it can, but there are going to be mappings to the ASM files for compiler-generated code, and for library code. Change PCEAS so that equates ('=' and ".equ") can have an optional parameter to set the label's size (for data), or whether it is "CODE or a "FUNC", which gets passed to the .sym file for debugging, but is otherwise unused by PCEAS itself. Change PCEAS to implement the ".DBG line" and ".DBG clear" pseudo-ops to enable HuCC to tag the original C source file, line and column of the ASM code that it generates. Change PCEAS to clean up all of the '\' and '/' characters in file paths so the paths match the host platform's native format.
…variables, and also add the FUNC flag to the System Card function entry points. These are used when exporting source-level-debugging information to mesen2. Update ipl-scd.asm to define the System Card functions that it uses because now those are not defined in pcengine.inc for non-CD/SCD builds, like ipl-scd.asm
…emulator. This is controlled with the "-gC", "-gA", or "-gL" command line flags to choose whether to output source mappings to the C, ASM, or PCEAS-generated .LST files. The .LST file gives the most information, because you see the macro expansions, but the ASM version might be preferable to developers who don't macros much. The C version will map to C source lines when it can, but there are going to be mappings to the ASM files for compiler-generated code, and for library code. Change PCEAS to clean up all of the '\' and '/' characters in file paths so the paths match the host platform's native format.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.