To properly create temporary array for a polymorphic result
of hlfir.elemental we need to keep the mold as its operand.
This patch adds just the basic support.
Details
Diff Detail
Event Timeline
Yesterday we had a lot of changes to flang land in one build: https://lab.llvm.org/buildbot/#/builders/197/builds/8782
Which broke some llvm-test-suite tests:
FAIL: test-suite::gfortran-regression-compile-regression__allocate_with_mold_4_f90.test FAIL: test-suite::gfortran-regression-compile-regression__c_ptr_tests_16_f90.test FAIL: test-suite::gfortran-regression-compile-regression__init_flag_17_f90.test
This is the start of that series, with another set from @klausler . Could you co-ordinate investigating this?
I am bisecting to see if I can get specific commits to blame for each test, but I'm sure you will be able to work it out from the failure messages instead. I don't have the fortran knowledge for that.
In general please don't land so many changes in one go unless you know you will be around to deal with the potential failures. It leads to folks like myself being tempted to revert the entire series, as we don't have the specific knowledge needed to know which subset actually caused the issue.
(of course we can't always know what our colleagues are doing, so there's always a chance it can happen that way)
Actually, this bot got a much smaller change list: https://lab.llvm.org/buildbot/#/builders/176/builds/3786
This starts with Peter's changes, but I'll keep the discussion here for simplicity's sake.
This has been fixed by https://github.com/llvm/llvm-test-suite/commit/5942ca45a1036ace15b70e117d636ecf89224957, thanks!