# Copyright (c) 2001, Stanford University
# All rights reserved.
#
# See the file LICENSE.txt for information on redistributing this software.
import sys
import apiutil
def GenerateEntrypoints():
print '#include "chromium.h"'
print '#include "stub.h"'
print ''
print '#define NAKED __declspec(naked)'
print '#define UNUSED(x) ((void)(x))'
print ''
# Get sorted list of dispatched functions.
# The order is very important - it must match cr_opcodes.h
# and spu_dispatch_table.h
continue
continue
print "{"
print "\t__asm jmp [glim.%s]" % func_name
print "\tUNUSED( %s );" % name
print "}"
print ""
print '/*'
print '* Aliases'
print '*/'
# Now loop over all the functions and take care of any aliases
continue
# we already processed this function earlier
continue
# alias is the function we're aliasing
if alias:
print "{"
print "\t__asm jmp [glim.%s]" % alias
print "\tUNUSED( %s );" % name
print "}"
print ""
print '/*'
print '* No-op stubs'
print '*/'
# Now generate no-op stub functions
print "{"
if return_type != "void":
print "return (%s) 0" % return_type
print "}"
print ""