I have been reading a big article about memory at http://lwn.net/Articles/250967/
After reading Part 5, it seems PB could benefit from the option to give the compiler hints about your code.
It should not be too hard to integrate into PB's syntax. A few examples of what it could look like.
IF EXPECT c%>127, EXPECT d%=55, c%<127 AND D% = 55 THEN DoSomething
IF EXPECT TRUE, NOT ErrorFlag THEN DoSomething
SUB DoSomething() HINT whatever ' hints about when and how often the SUB/FUNCTION is used
LOCAL MyCounter AS BYTE, MyName AS STRING
...
END SUB
DIM A(2530) AS DOUBLE NONTEMPORAL ' don't let this array go into cache, perhaps it is rarely needed
Any interest?
After reading Part 5, it seems PB could benefit from the option to give the compiler hints about your code.
It should not be too hard to integrate into PB's syntax. A few examples of what it could look like.
IF EXPECT c%>127, EXPECT d%=55, c%<127 AND D% = 55 THEN DoSomething
IF EXPECT TRUE, NOT ErrorFlag THEN DoSomething
SUB DoSomething() HINT whatever ' hints about when and how often the SUB/FUNCTION is used
LOCAL MyCounter AS BYTE, MyName AS STRING
...
END SUB
DIM A(2530) AS DOUBLE NONTEMPORAL ' don't let this array go into cache, perhaps it is rarely needed
Any interest?
Comment