This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Ada] Validity checks on boolean expressions


The value of a boolean expression or short-circuit operation is valid if the
elementary operands of the expression are valid. This patch removes validity
checks that were superfluous, and led to a quadratic expansion in the generated
code for short-circuit expressions with multiple alternatives.
No simple example available.

Tested on x86_64-pc-linux-gnu, committed on trunk

2010-09-10  Ed Schonberg  <schonberg@adacore.com>

	* checks.adb (Ensure_Valid): If the expression is a boolean expression
	or short-circuit operation, do no emit a validity check: only the
	elementary operands of the expression need checking.

Attachment: difs
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]