bors
d627cf07ce
Auto merge of #113915 - cjgillot:ssa-call, r=tmiasko
...
Also consider call and yield as MIR SSA.
The SSA analysis on MIR only considered `Assign` statements as defining a SSA local.
This PR adds assignments as part of a `Call` or `Yield` terminator in that category.
This mainly allows to perform CopyProp on a call return place.
The only subtlety is in the dominance property: the assignment is only complete at the beginning of the target block.
2023-10-10 20:37:55 +00:00
Oğuz Ağcayazı
4ff6e87a8c
return crates instead of a crate
2023-10-09 10:33:23 +03:00
Camille GILLOT
37f080edbc
Also consider call and yield as MIR SSA.
2023-10-08 16:05:26 +00:00
ouz-a
a79567b01c
add span to statements
2023-10-05 11:15:34 +03:00
Oli Scherer
a38e98371b
Split out the stable part of smir into its own crate to prevent accidental usage of forever unstable things
2023-09-25 14:38:27 +00:00
Oli Scherer
33998a9751
Fix test by adding a stable way to get an opaque DefKind
2023-09-25 14:38:27 +00:00
Oli Scherer
c2e790044c
Allow loading the SMIR for constants and statics
2023-09-11 08:14:56 +00:00
Oli Scherer
0f4ff52e00
Implement and test monomorphization
2023-09-06 08:16:04 +00:00
Oli Scherer
a370f1baa3
Also use Const
in SMIR
instead of just ConstantKind
2023-09-06 08:16:04 +00:00
Oli Scherer
7f009e54bd
Fail to test argument instantiation since we don't have types for most constants
2023-09-06 08:16:04 +00:00
Celina G. Val
d10d8290ac
Add tests and use ControlFlow
2023-09-05 09:19:56 -07:00
Celina G. Val
3b01f65aa5
Diferentiate between ICE and compilation error
2023-09-05 08:54:03 -07:00
ouz-a
c2fe0bf253
Create StableMir replacer for SMirCalls
2023-08-29 16:30:50 +03:00
Matthias Krüger
39f558f8cf
Rollup merge of #113412 - spastorino:smir-types-1, r=oli-obk
...
Add basic types to SMIR
Still incomplete but I think this can be merged and we can keep iterating over it.
r? ``@oli-obk``
2023-07-08 15:49:47 +02:00
Santiago Pastorino
9ca51b92d4
Add Float ty to SMIR
2023-07-07 13:47:55 -03:00
Santiago Pastorino
42eccffce3
Add Uint ty to SMIR
2023-07-07 13:47:33 -03:00
Santiago Pastorino
458ead41d6
Add Int ty to SMIR
2023-07-07 13:47:09 -03:00
Santiago Pastorino
73e816e37c
Add Char ty to SMIR
2023-07-07 13:46:40 -03:00
Santiago Pastorino
61adcaf87b
Add rustc_ty_to_ty basic tests
2023-07-07 13:45:54 -03:00
许杰友 Jieyou Xu (Joe)
cef812bd95
Provide more context for rustc +nightly -Zunstable-options
on stable
2023-06-27 23:23:33 +08:00
Oli Scherer
5c6e2342f6
Encode types in SMIR
2023-05-08 14:23:19 +00:00
Oli Scherer
7f74ae57e8
Create a trait to abstract over the smir API
2023-05-08 14:23:04 +00:00
Santiago Pastorino
4b85bea4ae
Add Assert terminator to SMIR
2023-05-05 10:34:52 -03:00
Santiago Pastorino
7dd59fceef
Add Drop terminator to SMIR
2023-05-03 18:38:15 -03:00
Santiago Pastorino
2f503345b4
Add Call terminator to SMIR
2023-04-20 12:00:41 -03:00
Oli Scherer
e404e77c0b
Add a stable MIR way to get the main function
2023-04-14 07:28:56 +00:00
Pietro Albini
bf66ddbf24
fix wrong ignore condition
2023-04-03 10:23:13 +02:00
Oli Scherer
480e042097
Add Debug and Clone derives for stable mir datastructures
2023-03-16 16:17:25 +00:00
Oli Scherer
942cac1b8d
Implement a minimal subset of MIR statements and terminators for smir
2023-03-16 16:06:12 +00:00
Celina G. Val
5eaeb71b9f
Change item collection to be on demand
2023-03-07 12:47:25 -08:00
Celina G. Val
b66db7e4e0
Create new rustc_smir struct to map future crates
...
+ Add some information to the README.md
2023-03-06 21:57:46 -08:00