- User Since
- Mar 16 2020, 6:35 AM (21 w, 4 d)
Fri, Jul 31
Thu, Jul 30
Looks good to me, thanks for implementing this.
Wed, Jul 29
Fri, Jul 24
In this very spot, the goal of the template is to digest the runtime headers in order to lower their function signature to an mlir::FuncOp declaration that is compatible with the runtime and will be call in user programs.
So if we use std::complex here and introduce a wrapper indirection in C around the runtime, then the cost of this indirection will be paid by the user program. I am not comfortable with having a Fortran programmer pay the price of a C/C++ compatibility issues.
Thu, Jul 23
Sorry I was harvesting potatoes far from any computers when all these discussions happened. First of all, thanks for detecting the warning and proposing a fix for it. I will try to explain our issue and why we cannot use safely std::complex here so we can find a fix for this.
Jul 3 2020
LGTM, thanks for doing this.
Jul 2 2020
Removed old FIXME that was actually implemented in fold-real.cc
Jun 25 2020
Jun 23 2020
Jun 22 2020
Why not updating semantics::IsSaved to test IsFunctionResult instead like it is doing with IsDummy ?
Lowering relies on IsSaved to indicate whether something is implicitly or explicitly saved, so with this patch it looks like we would still create a global for f2b even if we should not.
Jun 19 2020
Jun 17 2020
Add comments in AMAX0/MIN1... rewrite algorithm.
Jun 16 2020
LGTM, unit test can always be added later when the framework is ready.
Jun 4 2020
Jun 3 2020
May 6 2020
Thanks for adding these examples
Apr 29 2020
Apr 27 2020
Would it make sens to also upstream https://github.com/flang-compiler/f18-llvm-project/blob/fir-dev/flang/documentation/BijectiveInternalNameUniquing.md in this patch. It explains the rational of this mangling.
Otherwise looks good to me.
Apr 16 2020
Looks like originalFenv_ is still used for restoring the original state. Shall I change the type of originalFenv_ to be unsigned int on x86_64? (Or maybe a union?)
From what I understand originalFenv_ is used for changing and restoring the __mxcsr value (or its equivalents on aarch64).
In host.cpp, originalFenv_ is more than just the __mxcsr, it also backs-up the whole fp environment (original rounding mode, exceptions that were raised,...) before calling the run-time to fold. Interrupts are also disabled between the related feholdexcept / fesetenv (we do not want the compiler to crash if the Fortran code being folded is wrong and triggers a division by zero or such), so it should be kept.
currentFenv_ however was only about manipulating the __mxcsr (or __fpcr /...), so you can remove it where you do not need it anymore.