Commit graph

54 commits

Author SHA1 Message Date
Eric Schweitz
777b89fdee [flang] revert last pushes
Original-commit: flang-compiler/f18@39335746a9
2019-04-24 11:41:40 -07:00
Eric Schweitz
1c15fa61a8 [flang] fix merge issues
Original-commit: flang-compiler/f18@20a6d8a159
2019-04-24 11:14:28 -07:00
Eric Schweitz
ff9123927c [flang] clang-format
Original-commit: flang-compiler/f18@faa7ccf905
2019-04-24 11:14:27 -07:00
Eric Schweitz
0b7fa133ae [flang] Some initial bridge code
add QualifiedStmt class

Original-commit: flang-compiler/f18@b2d89fe696
2019-04-24 11:14:25 -07:00
Eric Schweitz
bb832078a1 [flang] start splitting up afforestation so it isn't monolithic
Original-commit: flang-compiler/f18@ea42c9df5a
2019-04-24 11:14:20 -07:00
Eric Schweitz
ac525ded21 [flang] fix interface
Original-commit: flang-compiler/f18@668fd8338d
2019-04-24 11:14:17 -07:00
Tim Keith
2dbd0dfb1c [flang] Change ExprRef to return reference
ExprRef never returns a null pointer so change it to return a reference.
Add overloading for parser::Variable as they now also hold a typedExpr.
Change some of the functions that the result of ExprRef is passed to so
that they take references instead of pointers.

Original-commit: flang-compiler/f18@2cdab6b166
Reviewed-on: https://github.com/flang-compiler/f18/pull/424
2019-04-21 20:46:15 -07:00
Tim Keith
510671c8c1 [flang] Distinguish between unanalyzed and error expressions
When an Expr or Variable is analyzed, always fill in a GenericExprWrapper
for it. That now holds the result of expression analysis which is
std::nullopt when there is an error.

After the ExprChecker pass has finished, the typedExpr data member of
Variables and top-level Exprs should be filled in. Assert that is the
case when we access them.

Original-commit: flang-compiler/f18@192a4e0855
Reviewed-on: https://github.com/flang-compiler/f18/pull/424
Tree-same-pre-rewrite: false
2019-04-19 17:14:50 -07:00
Eric Schweitz
da8d735a00 [flang] tweak comment
Original-commit: flang-compiler/f18@7f5f440439
Reviewed-on: https://github.com/flang-compiler/f18/pull/408
2019-04-12 10:22:09 -07:00
Eric Schweitz
d653839dd3 [flang] handle review comment: make ctor private
Original-commit: flang-compiler/f18@cc6bf19f81
Reviewed-on: https://github.com/flang-compiler/f18/pull/408
Tree-same-pre-rewrite: false
2019-04-12 10:19:41 -07:00
Eric Schweitz
80c3d5cfc3 [flang] various code cleanups from QualifiedType reviews
Original-commit: flang-compiler/f18@b17f24da8f
Reviewed-on: https://github.com/flang-compiler/f18/pull/408
Tree-same-pre-rewrite: false
2019-04-12 09:21:29 -07:00
Eric Schweitz
4ebcf8b702 [flang] add std::move per review comments
Original-commit: flang-compiler/f18@0f3c1616ed
Reviewed-on: https://github.com/flang-compiler/f18/pull/399
2019-04-11 09:50:55 -07:00
Eric Schweitz
af375b2560 [flang] add QualifiedStmt class
Original-commit: flang-compiler/f18@6bc660c355
Reviewed-on: https://github.com/flang-compiler/f18/pull/399
Tree-same-pre-rewrite: false
2019-04-09 11:52:04 -07:00
Eric Schweitz
253f361152 [flang] make the ctor use special type deduction so members can be moved and
copied in the same call

Original-commit: flang-compiler/f18@d18e8391fc
Reviewed-on: https://github.com/flang-compiler/f18/pull/393
2019-04-09 11:36:42 -07:00
Eric Schweitz
2f64d464d5 [flang] fix forward references
Original-commit: flang-compiler/f18@4d8902887d
Reviewed-on: https://github.com/flang-compiler/f18/pull/393
Tree-same-pre-rewrite: false
2019-04-09 11:36:28 -07:00
Eric Schweitz
3151250d43 [flang] more fine-tuning of mixin classes to get lightweight constructors,
handle copies and moves, etc.

Original-commit: flang-compiler/f18@72a776b4c1
Reviewed-on: https://github.com/flang-compiler/f18/pull/385
2019-04-08 12:57:46 -07:00
Eric Schweitz
dbd8533e39 [flang] use std::forward, avoid std::move usage bugs
Original-commit: flang-compiler/f18@0d66bc2439
Reviewed-on: https://github.com/flang-compiler/f18/pull/385
Tree-same-pre-rewrite: false
2019-04-05 11:17:42 -07:00
Eric Schweitz
02faca4bb5 [flang] anchor virtual dtor
Original-commit: flang-compiler/f18@7121ccecb2
Reviewed-on: https://github.com/flang-compiler/f18/pull/385
Tree-same-pre-rewrite: false
2019-04-05 11:17:27 -07:00
peter klausler
9e9b9f0776 [flang] Pass tests
Original-commit: flang-compiler/f18@ffb057f262
Reviewed-on: https://github.com/flang-compiler/f18/pull/371
Tree-same-pre-rewrite: false
2019-04-01 12:30:08 -07:00
peter klausler
95b4e65ecf [flang] Move some AsFortran() implementations into new formatting.cc; use precedence for parentheses
Original-commit: flang-compiler/f18@2b5fa051df
Reviewed-on: https://github.com/flang-compiler/f18/pull/371
Tree-same-pre-rewrite: false
2019-04-01 10:58:55 -07:00
Steve Scalpone
1de9ecd251 [flang] Add CMake rules to install static and shared libraries in
the default install directory or in the directory specified
with CMAKE_INSTALL_PREFIX.  Fixes flang-compiler/f18#359.

Original-commit: flang-compiler/f18@35ce1628e2
Reviewed-on: https://github.com/flang-compiler/f18/pull/364
2019-03-28 09:55:56 -07:00
Eric Schweitz
de2f753810 [flang] add comment per Steve's request in review
Original-commit: flang-compiler/f18@c3a5d6a15e
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
2019-03-27 16:03:52 -07:00
Eric Schweitz
1b7aea8ebc [flang] Change per Jean's review comment
Original-commit: flang-compiler/f18@9a3a79927b
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-27 08:58:59 -07:00
Eric Schweitz
dbccd231ba [flang] remove use of undefined behavior
Original-commit: flang-compiler/f18@d7c5879f2c
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-25 19:16:41 -07:00
Eric Schweitz
1410957864 [flang] temporary symbol creation and improve dump routine
check for labels on construct delimiting statements
ifdef out code to avoid warning

Original-commit: flang-compiler/f18@667674aaa0
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-25 09:29:01 -07:00
Eric Schweitz
15d3eb92e5 [flang] remove the DO stub instructions
Original-commit: flang-compiler/f18@f1ddcd8d76
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
Eric Schweitz
f76ba41bb3 [flang] build up expressions implied by DO loop construct
Original-commit: flang-compiler/f18@1e7b9adb62
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
Eric Schweitz
19ec665cbf [flang] simplify switch builders
Original-commit: flang-compiler/f18@787ee1fecd
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
Eric Schweitz
84264dc79b [flang] improved output on flat fir
Original-commit: flang-compiler/f18@9be07963a5
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
Eric Schweitz
9e98210438 [flang] refactor linear representation -> flattened
Original-commit: flang-compiler/f18@4253e2484f
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
Eric Schweitz
73ee96f7ce [flang] replace GenericExprWrapper with Expr<SomeType>
Original-commit: flang-compiler/f18@0821d00cb8
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
Eric Schweitz
00a3ccd91d [flang] FIR: more code cleanup
Original-commit: flang-compiler/f18@eaac944aca
Reviewed-on: https://github.com/flang-compiler/f18/pull/354
Tree-same-pre-rewrite: false
2019-03-23 11:14:20 -07:00
peter klausler
ad057a42fa [flang] Remove OwningPointer, use unique_ptr better instead.
Original-commit: flang-compiler/f18@89aff868aa
Reviewed-on: https://github.com/flang-compiler/f18/pull/346
Tree-same-pre-rewrite: false
2019-03-20 11:38:45 -07:00
Eric
6b09d21b13 [flang] more compiler warnings
Original-commit: flang-compiler/f18@df8c83c106
Reviewed-on: https://github.com/flang-compiler/f18/pull/334
2019-03-15 18:57:52 -07:00
Eric Schweitz
862ff5bf80 [flang] review comments
Original-commit: flang-compiler/f18@1ba1c0268f
Reviewed-on: https://github.com/flang-compiler/f18/pull/334
Tree-same-pre-rewrite: false
2019-03-15 16:23:10 -07:00
Eric Schweitz
0e96269737 [flang] muzzle clang++ warnings
Original-commit: flang-compiler/f18@02decb4040
Reviewed-on: https://github.com/flang-compiler/f18/pull/334
Tree-same-pre-rewrite: false
2019-03-15 11:35:18 -07:00
Eric Schweitz
327fa06a6b [flang] replace the stubs for translating terminal symbols to expressions; start pushing Value type into FIR; cleanup terminator succ_blocks; remove parser element from disassociate; run clang-format; etc.
Original-commit: flang-compiler/f18@c5561646ea
Reviewed-on: https://github.com/flang-compiler/f18/pull/334
Tree-same-pre-rewrite: false
2019-03-15 10:03:06 -07:00
Eric Schweitz
388ce79539 [flang] Move virtual dtor to Terminator
Original-commit: flang-compiler/f18@68853d602a
Reviewed-on: https://github.com/flang-compiler/f18/pull/328
2019-03-11 18:37:30 -07:00
Eric Schweitz
311c9b5a89 [flang] remove unused files
Cleanup some warnings when building with clang.

Original-commit: flang-compiler/f18@33cf6255d1
Reviewed-on: https://github.com/flang-compiler/f18/pull/328
Tree-same-pre-rewrite: false
2019-03-11 12:24:16 -07:00
Eric Schweitz
dfa5010e47 [flang] Revisions for review comments.
Original-commit: flang-compiler/f18@1a03f7d5bb
Reviewed-on: https://github.com/flang-compiler/f18/pull/324
2019-03-11 09:38:45 -07:00
Eric Schweitz
cf18b7a6bd [flang] Fix build breakage
Original-commit: flang-compiler/f18@72d003f89d
Reviewed-on: https://github.com/flang-compiler/f18/pull/323
2019-03-11 09:16:01 -07:00
Eric Schweitz
4fd1e5d795 [flang] Address review comments; merge with latest breaking changes on master
Original-commit: flang-compiler/f18@ffde96d486
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
2019-03-11 08:59:33 -07:00
Eric Schweitz
829e8247ed [flang] Run old clang-format over FIR directory
Original-commit: flang-compiler/f18@0616ac43ec
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
Tree-same-pre-rewrite: false
2019-03-11 08:57:41 -07:00
Eric Schweitz
686d4daf6c [flang] Repairs for new interfaces
Original-commit: flang-compiler/f18@1a080dfe6a
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
Tree-same-pre-rewrite: false
2019-03-11 08:57:41 -07:00
Eric Schweitz
d6964c42f2 [flang] FIR statements: various reworking of the code to decompose some
operations, get rid of unneeded nodes, restructure DO loops, etc.

Original-commit: flang-compiler/f18@0e0d67fbda
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
Tree-same-pre-rewrite: false
2019-03-11 08:57:41 -07:00
Eric Schweitz
2ad50e0712 [flang] react to more review comments
Original-commit: flang-compiler/f18@b685d8a588
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
Tree-same-pre-rewrite: false
2019-03-11 08:56:36 -07:00
Eric Schweitz
1ee88d3c81 [flang] Fixes for building with clang++ and other misc. from review
Original-commit: flang-compiler/f18@c3cdc32786
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
Tree-same-pre-rewrite: false
2019-03-11 08:56:36 -07:00
Eric Schweitz
a981cd5b9e [flang] Move over build recipes and rename the library
Original-commit: flang-compiler/f18@51476aa178
Reviewed-on: https://github.com/flang-compiler/f18/pull/319
Tree-same-pre-rewrite: false
2019-03-11 08:56:36 -07:00
peter klausler
ab74d1ac0c [flang] Rename to Fortran.h, update style guide, run clang-format
Original-commit: flang-compiler/f18@aa2907d226
Reviewed-on: https://github.com/flang-compiler/f18/pull/308
Tree-same-pre-rewrite: false
2019-02-28 11:48:15 -08:00
Eric Schweitz
e913651945 [flang] address review comments
Original-commit: flang-compiler/f18@b1c731b026
Reviewed-on: https://github.com/flang-compiler/f18/pull/294
2019-02-22 15:38:57 -08:00