Skip to content
Snippets Groups Projects
  • Jakub Jelinek's avatar
    5a0f4dd3
    omp-low.c (extract_omp_for_data): For collapsed loops... · 5a0f4dd3
    Jakub Jelinek authored
    	* omp-low.c (extract_omp_for_data): For collapsed loops,
    	if at least one of the loops is known at compile time to
    	iterate zero times, set count to 0.
    	(expand_omp_regimplify_p): New function.
    	(expand_omp_for_generic): For collapsed loops, if at least
    	one of the loops isn't known to iterate at least once,
    	add runtime check with setting count to 0.
    	(expand_omp_for_static_nochunk, expand_omp_for_static_chunk):
    	For unsigned types if it isn't known at compile time that
    	the loop will iterate at least once, add runtime check to bypass
    	the whole loop if initial condition isn't true.
    
    	* testsuite/libgomp.c/loop-13.c: New test.
    	* testsuite/libgomp.c/loop-14.c: New test.
    	* testsuite/libgomp.c/loop-15.c: New test.
    	* testsuite/libgomp.c++/loop-13.C: New test.
    	* testsuite/libgomp.c++/loop-14.C: New test.
    	* testsuite/libgomp.c++/loop-15.C: New test.
    
    From-SVN: r198966
    5a0f4dd3
    History
    omp-low.c (extract_omp_for_data): For collapsed loops...
    Jakub Jelinek authored
    	* omp-low.c (extract_omp_for_data): For collapsed loops,
    	if at least one of the loops is known at compile time to
    	iterate zero times, set count to 0.
    	(expand_omp_regimplify_p): New function.
    	(expand_omp_for_generic): For collapsed loops, if at least
    	one of the loops isn't known to iterate at least once,
    	add runtime check with setting count to 0.
    	(expand_omp_for_static_nochunk, expand_omp_for_static_chunk):
    	For unsigned types if it isn't known at compile time that
    	the loop will iterate at least once, add runtime check to bypass
    	the whole loop if initial condition isn't true.
    
    	* testsuite/libgomp.c/loop-13.c: New test.
    	* testsuite/libgomp.c/loop-14.c: New test.
    	* testsuite/libgomp.c/loop-15.c: New test.
    	* testsuite/libgomp.c++/loop-13.C: New test.
    	* testsuite/libgomp.c++/loop-14.C: New test.
    	* testsuite/libgomp.c++/loop-15.C: New test.
    
    From-SVN: r198966
To find the state of this project's repository at the time of any of these versions, check out the tags.