aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/analyzer.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/analyzer.js b/src/analyzer.js
index fa8aee59..c09739e9 100644
--- a/src/analyzer.js
+++ b/src/analyzer.js
@@ -467,6 +467,12 @@ function analyzer(data, sidePass) {
break;
}
case 'bitcast': {
+ if (!sourceBits) {
+ // we can be asked to bitcast doubles or such to integers, handle that as best we can (if it's a double that
+ // was an x86_fp80, this code will likely break when called)
+ sourceBits = targetBits = Runtime.getNativeTypeSize(value.params[0].type);
+ warn('legalizing non-integer bitcast on ll #' + item.lineNum);
+ }
break;
}
case 'select': {