Patent ID: 6317876
Filing Date: 2001-11-13
Classification: G06F

Abstract:
A method for determining the maximum number of live registers in a computer system, said computer system having an executing computer program having at least one instruction that accesses said registers, said method comprising:including a read instruction in said instructions, and said live registers being associated with said read instruction;associating events in said computer program with said instructions, and thereby associating said accessed registers with said events;wherein, for each said event:identifying when said event is associated with each said accessed register, determining when each said accessed register associated with said event is said live register, and representing said live registers associated with said event quantity by a numberofliveregisters variable associated with said event;identifying each said accessed register associated with said event as touched with respect to said event, and representing said touched registers associated with said event by a registerswithknowninformation variable associated with said event;identifying each register pressure information variable associated with said event, said register pressure information variable including said numberofliveregisters variable associated with said event and said registerswithknowninformation variable associated with said event, and recording said register pressure information variable associated with said event when said registerswithknowninformation variable associated with said register pressure information variable corresponding to said event represents said registers that have not been previously touched;combining said register pressure information variable corresponding to a previous said each event with said register pressure information variable corresponding to said event, when said registerswithknowninformation variable associated with said register pressure information variable corresponding to said event represents a said register that has not been previously touched;retaining said register pressure information variable corresponding to said previous each event when said registerswithknowninformation variable associated with said register pressure information variable corresponding to said event is equivalent to said registerswithknowninformation variable associated with said register pressure information variable corresponding to said previous each event;associating said register pressure information variable corresponding to said event with an uncertainty level variable that represents said registers associated with said event that have not been touched quantity;retaining said register pressure information variable with a largest value of said numberofliveregisters variable associated with said event when said register pressure information variable is associated with: different values of said numberofliveregisters variables associated with said event and equivalent values of said registerswithknowninformation variables associated with said event; andretaining one said register pressure information variable associated with said event when a plurality of said register pressure information variables is associated with said event, and said numberofliveregisters variables and said registerswithknowninformation variables associated with said plurality of said register pressure information variables are equivalent; anddetermining a largest value of said numberofliveregisters variable associated with said events in said computer program and thereby identifying said maximum number of live registers in said computer system.