diff options
author | Xavier Leroy <xavier.leroy@inria.fr> | 2019-04-15 17:50:30 +0200 |
---|---|---|
committer | Xavier Leroy <xavierleroy@users.noreply.github.com> | 2019-05-20 18:00:46 +0200 |
commit | 49342474c19558709c8cea6d70eaba9a4dd7a150 (patch) | |
tree | 86fb6e9fc2081a71a2d770811164bb2f72b867e6 /arm/SelectOp.vp | |
parent | 996f2e071baaf52105714283d141af2eac8ffbfb (diff) | |
download | compcert-49342474c19558709c8cea6d70eaba9a4dd7a150.tar.gz compcert-49342474c19558709c8cea6d70eaba9a4dd7a150.zip |
Implement a `Osel` operation for ARM
The operation comples down to conditional moves.
Both integer and floating-point conditional moves are supported.
Diffstat (limited to 'arm/SelectOp.vp')
-rw-r--r-- | arm/SelectOp.vp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arm/SelectOp.vp b/arm/SelectOp.vp index c361df65..61ea6283 100644 --- a/arm/SelectOp.vp +++ b/arm/SelectOp.vp @@ -382,6 +382,9 @@ Definition compf (c: comparison) (e1: expr) (e2: expr) := Definition compfs (c: comparison) (e1: expr) (e2: expr) := Eop (Ocmp (Ccompfs c)) (e1 ::: e2 ::: Enil). +Definition select (ty: typ) (cond: condition) (args: exprlist) (e1 e2: expr) := + Some (Eop (Osel cond ty) (e1 ::: e2 ::: args)). + (** ** Integer conversions *) Definition cast8unsigned (e: expr) := andimm (Int.repr 255) e. |