mirror of
https://github.com/pevans/erc-c.git
synced 2024-11-27 20:51:17 +00:00
Add missing docblock comments
This commit is contained in:
parent
c3d35dca72
commit
1c36c4ea4d
@ -446,6 +446,10 @@ mos6502_would_jump(int inst_code)
|
||||
inst_code == JSR;
|
||||
}
|
||||
|
||||
/*
|
||||
* Here we copy the segment directly into the cpu memory, to essentially
|
||||
* "flash" memory with the contents of another segment.
|
||||
*/
|
||||
void
|
||||
mos6502_flash_memory(mos6502 *cpu, vm_segment *segment)
|
||||
{
|
||||
|
@ -309,6 +309,10 @@ mos6502_dis_opcode(mos6502 *cpu, FILE *stream, int address)
|
||||
return expected + 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Scan the CPU memory, from a given position until a given end, and
|
||||
* print the results into a given file stream.
|
||||
*/
|
||||
void
|
||||
mos6502_dis_scan(mos6502 *cpu, FILE *stream, int pos, int end)
|
||||
{
|
||||
@ -317,6 +321,12 @@ mos6502_dis_scan(mos6502 *cpu, FILE *stream, int pos, int end)
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Associate a label with a given address or operand, depending on the
|
||||
* address mode. For example, with REL, the jump label will be based on
|
||||
* the address but added to or subtracted with the operand. Whereas in
|
||||
* IND, the address is wholly dependent on the operand.
|
||||
*/
|
||||
void
|
||||
mos6502_dis_jump_label(mos6502 *cpu,
|
||||
vm_16bit operand,
|
||||
@ -355,18 +365,29 @@ mos6502_dis_jump_label(mos6502 *cpu,
|
||||
jump_table[jump_loc] = 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Print out the form of our label to the given file stream. This is
|
||||
* fairly dumb; it'll print out whatever address you give to it.
|
||||
*/
|
||||
inline void
|
||||
mos6502_dis_label(FILE *stream, int address)
|
||||
{
|
||||
fprintf(stream, "ADDR_%d", address);
|
||||
}
|
||||
|
||||
/*
|
||||
* Remove the previously-set label in the jump table for a given
|
||||
* address.
|
||||
*/
|
||||
inline void
|
||||
mos6502_dis_jump_unlabel(int address)
|
||||
{
|
||||
jump_table[address] = 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Return true if the given address has a jump label associated with it.
|
||||
*/
|
||||
inline bool
|
||||
mos6502_dis_is_jump_label(int address)
|
||||
{
|
||||
|
@ -51,6 +51,9 @@ objstore_init()
|
||||
return OK;
|
||||
}
|
||||
|
||||
/*
|
||||
* Return true if the object store is ready to be used.
|
||||
*/
|
||||
bool
|
||||
objstore_ready()
|
||||
{
|
||||
|
@ -280,6 +280,9 @@ option_get_height()
|
||||
return height;
|
||||
}
|
||||
|
||||
/*
|
||||
* Return true if the given option flag is set.
|
||||
*/
|
||||
bool
|
||||
option_flag(int flag)
|
||||
{
|
||||
|
@ -211,6 +211,10 @@ vm_screen_draw_rect(vm_screen *screen, vm_area *area)
|
||||
SDL_RenderFillRect(screen->render, &rect);
|
||||
}
|
||||
|
||||
/*
|
||||
* Assign the values of an area, which are an x and y offset plus a
|
||||
* width and height.
|
||||
*/
|
||||
inline void
|
||||
vm_area_set(vm_area *area, int xoff, int yoff, int width, int height)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user