8sa1-gcc/gcc/testsuite/g++.dg/pr79764.C
Martin Liska a278b1c38f Support BIT_FIELD_REF in MPX (PR ipa/79764).
2017-03-09  Martin Liska  <mliska@suse.cz>

	PR ipa/79764
	(chkp_narrow_size_and_offset): New function.
	(chkp_parse_array_and_component_ref): Support BIT_FIELD_REF.
	(void chkp_parse_bit_field_ref): New function.
	(chkp_make_addressed_object_bounds): Add case for BIT_FIELD_REF.
	(chkp_process_stmt): Use chkp_parse_bit_field_ref.
2017-03-09  Martin Liska  <mliska@suse.cz>

	PR ipa/79764
	* g++.dg/pr79764.C: New test.

From-SVN: r245994
2017-03-09 09:26:45 +00:00

13 lines
308 B
C

/* { dg-do compile { target { { i?86-*-* x86_64-*-* } && { ! x32 } } } } */
/* { dg-options "-fcheck-pointer-bounds -mmpx" } */
typedef float __m256 __attribute__ (( __vector_size__(32), __may_alias__ ));
struct A {
__m256 ymm;
const float &f() const;
};
const float &A::f() const {
return ymm[1];
}