<feed xmlns='http://www.w3.org/2005/Atom'>
<title>tools.nes/tests/delayed_macro_arguments.s, branch main</title>
<subtitle>Tools for NES/Famicom development.
</subtitle>
<id>https://git.mssola.com/nes/tools.nes/atom?h=main</id>
<link rel='self' href='https://git.mssola.com/nes/tools.nes/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://git.mssola.com/nes/tools.nes/'/>
<updated>2026-04-28T14:23:14Z</updated>
<entry>
<title>Send an error for unused .proc's</title>
<updated>2026-04-28T14:23:14Z</updated>
<author>
<name>Miquel Sabaté Solà</name>
<email>mssola@mssola.com</email>
</author>
<published>2026-04-28T14:06:33Z</published>
<link rel='alternate' type='text/html' href='https://git.mssola.com/nes/tools.nes/commit/?id=f7b42b2c26481734a4214aac856b33a942c93c23'/>
<id>urn:sha1:f7b42b2c26481734a4214aac856b33a942c93c23</id>
<content type='text'>
We cannot safely detect all scenarios in which there is dead code, but
we can safely do it for .proc's. Even if they are not called directly,
they might be referenced via jump tables and shenanigans like that. Long
story short, if you are not referencing a .proc in any meaningful way,
then we have dead code.

A pattern could also be given in which a function that was too long has
been splitted into smaller functions which are not called
directly. This is, in my opinion, an anti-pattern (as we generally
expect an rts or a jmp from .proc's), and anyways can be avoided via the
use of __fallthrough__ if the programmer is really set to write this
kind of code.

Signed-off-by: Miquel Sabaté Solà &lt;mssola@mssola.com&gt;
</content>
</entry>
<entry>
<title>Implement the asan:stack statement</title>
<updated>2026-04-08T14:04:12Z</updated>
<author>
<name>Miquel Sabaté Solà</name>
<email>mssola@mssola.com</email>
</author>
<published>2026-04-08T14:04:12Z</published>
<link rel='alternate' type='text/html' href='https://git.mssola.com/nes/tools.nes/commit/?id=a2cb050ca18fd7c5533d69e9aa093e4f0a40d0fa'/>
<id>urn:sha1:a2cb050ca18fd7c5533d69e9aa093e4f0a40d0fa</id>
<content type='text'>
This statement allows programmers to reserve a memory range for the
stack. This is useful to reserve a memory region which is not attached
to any variable, and:

1. It is a way to safely reserve space on the $0100 page.
2. The --stats/--write-info flags will be able to add up the memory
   space reserved for the stack.
3. Future tooling might be able to use this value as a way to detect
   stack overflows.

Signed-off-by: Miquel Sabaté Solà &lt;mssola@mssola.com&gt;
</content>
</entry>
<entry>
<title>Re-create the values for bundle call arguments</title>
<updated>2026-03-09T23:21:38Z</updated>
<author>
<name>Miquel Sabaté Solà</name>
<email>mssola@mssola.com</email>
</author>
<published>2026-03-09T23:14:33Z</published>
<link rel='alternate' type='text/html' href='https://git.mssola.com/nes/tools.nes/commit/?id=abaffa61df7db8522d29869f7c455c59b8e96dbc'/>
<id>urn:sha1:abaffa61df7db8522d29869f7c455c59b8e96dbc</id>
<content type='text'>
Bundle call arguments were fine most of the times, when arguments could
be processed as-is and there were no issues with arguments being
overwritten by successive calls.

This was not the case, though, whenever a given instruction was delayed
into a PendingNode status. In this case, the argument would get the
last value, and in some extreme cases that definition might not have
been there any more.

Prevent all of this by providing a list of PendingDefine's, which are a
way to re-create these call-only arguments as they were initially
found. These PendingDefine's are then created on "crunch" on each
PendingNode.

Signed-off-by: Miquel Sabaté Solà &lt;mssola@mssola.com&gt;
</content>
</entry>
</feed>
