mirror of
https://github.com/gbdev/rgbds.git
synced 2026-10-06 04:05:38 +00:00
Add __CYCLES__ variable to count cycles used by instructions (#2171)
This commit is contained in:
1 parent
6e2e2f1db7
commit
62a9d8d518
7 files changed
+192
No files matched your search
@@ -40,6 +40,7 @@ struct Section {
|
||||
uint16_t alignOfs;
|
||||
std::deque<Patch> patches;
|
||||
std::vector<uint8_t> data;
|
||||
uint32_t cyclesCounter; // `__CYCLES__` value; unsigned for well-defined overflow on increment
|
||||
|
||||
SectionTypeInfo const &typeInfo() const { return sectionTypeInfo[type]; }
|
||||
|
||||
|
||||
@@ -83,6 +83,7 @@ Symbol *sym_RedefEqu(InternedStr symName, int32_t value);
|
||||
Symbol *sym_AddVar(InternedStr symName, int32_t value);
|
||||
int32_t sym_GetRSValue();
|
||||
void sym_SetRSValue(int32_t value);
|
||||
void sym_IncrementCYCLESValue(uint32_t delta);
|
||||
// Find a symbol by exact name, bypassing expansion checks
|
||||
Symbol *sym_FindExactSymbol(InternedStr symName);
|
||||
// Find a symbol, possibly scoped, by name
|
||||
|
||||
Reference in new issue
Block a user