diff options
author | Bernhard Schommer <bernhardschommer@gmail.com> | 2015-09-02 15:56:42 +0200 |
---|---|---|
committer | Bernhard Schommer <bernhardschommer@gmail.com> | 2015-09-02 15:56:42 +0200 |
commit | 30ebbcd0731f680d1d283afb99318fb9d6e9cead (patch) | |
tree | a831b811de8502b0742f392cd3716ef1cd280336 /powerpc/Asmexpand.ml | |
parent | ba235b5d841528ac87b5c8cca79df3734a4a8976 (diff) | |
download | compcert-30ebbcd0731f680d1d283afb99318fb9d6e9cead.tar.gz compcert-30ebbcd0731f680d1d283afb99318fb9d6e9cead.zip |
Allow only CT values of 0 and 2 in dcbtls instruction.
The dcbtls instruction allows only the values 0 and 2 according to
the PPC Isa.
Diffstat (limited to 'powerpc/Asmexpand.ml')
-rw-r--r-- | powerpc/Asmexpand.ml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/powerpc/Asmexpand.ml b/powerpc/Asmexpand.ml index e0357a4a..caf256ef 100644 --- a/powerpc/Asmexpand.ml +++ b/powerpc/Asmexpand.ml @@ -363,7 +363,7 @@ let expand_builtin_prefetch addr rw loc = expand_builtin_cache_common addr emit_prefetch_instr let expand_builtin_dcbtls addr loc = - if not ((loc >= _0) && (loc <= _2)) then + if not ((loc == _0) || (loc = _2)) then raise (Error "the second argument of __builtin_dcbtls must be a constant between 0 and 2"); let emit_inst addr = emit (Pdcbtls (loc,addr)) in expand_builtin_cache_common addr emit_inst |