This is an archive of the discontinued LLVM Phabricator instance.

[mips][msa] Range adjustment for ldi_b builtin function operand
ClosedPublic

Authored by smaksimovic on Mar 17 2017, 8:22 AM.

Details

Summary

Reasoning behind this change was allowing the function to accept all values from range [-128, 255] since all of them can be encoded in an 8bit wide value.
This differs from the prior state where only range [-128, 127] was accepted, where values were assumed to be signed, whereas now the actual interpretation
of the immediate is deferred to the consumer as required.

Diff Detail

Event Timeline

smaksimovic created this revision.Mar 17 2017, 8:22 AM
sdardis accepted this revision.Mar 20 2017, 7:25 AM

Can you add a test to test/CodeGen/builtins-mips-msa.c covering the new extended range for ldi.b ?

LGTM.

This revision is now accepted and ready to land.Mar 20 2017, 7:25 AM

Added a new test to test/CodeGen/builtins-mips-msa.c, covering the new extended range for ldi.b.

This revision was automatically updated to reflect the committed changes.