int main(void)
This is the entry point signature the Xenon SDK expects for all traditional games. Contrary to wikis that claim
void main(void) or int main(int argc, char *argv[]), the signature only takes a void parameter and returns an integer.
void mainCRTStartup(void)
This is similar to Windows' mainCRTStartup function, but tailored for the 360. It internally sets up argv and argc but does not pass them to user code.
XamLoaderTerminateTitle(DbgPrint("[XAPI RETURN VALUE] %d\n",main_int)) happens on termination.
void XamLoaderTerminateTitle(UINT ExitCode)
This function is used to terminate the title and return control to the dashboard. The parameter is an unsigned integer exit code that can be used for debugging or signaling purposes.
LPVOID XPhysicalAllocEx(SIZE_T dwSize, LPVOID lpLowAddress, LPVOID lpHighAddress, DWORD dwAlignment, DWORD flAllocationType)
This function is used to allocate physical memory on the Xbox 360. The parameters are as follows:
The 360 did not have a modern concept of paging.
void XPhysicalFree(LPVOID lpAddress)
This function is used to free physical memory that was previously allocated with XPhysicalAllocEx. The parameter is as follows: