| US 7,526,761 B2 | ||
| Exception handling compiler apparatus, program, recording medium, and compiling method | ||
| Takeshi Ogasawara, Hachioji (Japan) | ||
| Assigned to International Business Machines Corporation, Armonk, N.Y. (US) | ||
| Filed on Mar. 16, 2004, as Appl. No. 10/801,879. | ||
| Claims priority of application No. 2003-079010 (JP), filed on Mar. 20, 2003. | ||
| Prior Publication US 2004/0230962 A1, Nov. 18, 2004 | ||
| Int. Cl. G06F 9/45 (2006.01) | ||
| U.S. Cl. 717—159 | 3 Claims |

| 1. A compiling method for causing a computer to operate as a compiler apparatus that optimizes exception handling in a target
program as a program to be compiled, comprising:
detecting, from exception handlers that catch exceptions thrown in said target program, a multiple-catching exception handler
catching a plurality of different exceptions and rethrowing the caught exceptions;
selecting a set of exceptions that are to be shifted to common processing through rethrow of the exceptions from among said
plurality of exceptions caught;
throwing a clone exception handler catching the set of exceptions selected by said step of selecting;
shifting the set of exceptions to said common processing;
said common processing includes catching exceptions that are thrown while processing a function that has been called with
a function call outside said function call;
said multiple-catching exception handler catches exceptions inside said function call; and
said selecting selects said set of exceptions further on condition that depth of nesting of function call from said common
processing down to said multiple-catching exception handler is more than a predetermined number.
|