• Home
  • Raw
  • Download

Lines Matching refs:tp

148   static bool isInteger(Type tp) {  in isInteger()  argument
149 return tp == kInt || tp == kLong; in isInteger()
153 static bool isFP(Type tp) { in isFP() argument
154 return tp == kFloat || tp == kDouble; in isFP()
158 void emitType(Type tp) const { in emitType()
159 switch (tp) { in emitType()
169 void emitTypeClass(Type tp) const { in emitTypeClass()
170 switch (tp) { in emitTypeClass()
201 void emitUnaryOp(Type tp) { in emitUnaryOp() argument
202 if (tp == kBoolean) { in emitUnaryOp()
204 } else if (isInteger(tp)) { in emitUnaryOp()
212 void emitIncDecOp(Type tp) { in emitIncDecOp() argument
213 if (tp == kBoolean) { in emitIncDecOp()
221 void emitBinaryOp(Type tp) { in emitBinaryOp() argument
222 if (tp == kBoolean) { in emitBinaryOp()
224 } else if (isInteger(tp)) { in emitBinaryOp()
232 void emitAssignmentOp(Type tp) { in emitAssignmentOp() argument
233 if (tp == kBoolean) { in emitAssignmentOp()
235 } else if (isInteger(tp)) { in emitAssignmentOp()
243 void emitRelationalOp(Type tp) { in emitRelationalOp() argument
244 if (tp == kBoolean) { in emitRelationalOp()
252 Type emitTypeConversionOp(Type tp) { in emitTypeConversionOp() argument
253 if (tp == kInt) { in emitTypeConversionOp()
262 } else if (tp == kLong) { in emitTypeConversionOp()
272 } else if (tp == kFloat) { in emitTypeConversionOp()
280 } else if (tp == kDouble) { in emitTypeConversionOp()
290 return tp; // nothing suitable, just keep type in emitTypeConversionOp()
294 void emitTypeConversion(Type tp) { in emitTypeConversion() argument
295 if (tp == kBoolean) { in emitTypeConversion()
296 Type tp = randomType(); in emitTypeConversion() local
297 emitExpression(tp); in emitTypeConversion()
299 emitRelationalOp(tp); in emitTypeConversion()
301 emitExpression(tp); in emitTypeConversion()
303 tp = emitTypeConversionOp(tp); in emitTypeConversion()
305 emitExpression(tp); in emitTypeConversion()
310 Type emitIntrinsic1(Type tp) { in emitIntrinsic1() argument
311 if (tp == kBoolean) { in emitIntrinsic1()
320 } else if (isInteger(tp)) { in emitIntrinsic1()
321 const char* prefix = tp == kLong ? "Long" : "Integer"; in emitIntrinsic1()
336 return tp == kLong ? kDouble : kFloat; in emitIntrinsic1()
345 case 6: if (tp == kDouble) { in emitIntrinsic1()
354 return tp; // same type in-out in emitIntrinsic1()
358 Type emitIntrinsic2(Type tp) { in emitIntrinsic2() argument
359 if (tp == kBoolean) { in emitIntrinsic2()
365 } else if (isInteger(tp)) { in emitIntrinsic2()
366 const char* prefix = tp == kLong ? "Long" : "Integer"; in emitIntrinsic2()
381 const char* prefix = tp == kDouble ? "Double" : "Float"; in emitIntrinsic2()
390 return tp; // same type in-out in emitIntrinsic2()
394 void emitIntrinsic(Type tp) { in emitIntrinsic() argument
396 tp = emitIntrinsic1(tp); in emitIntrinsic()
398 emitExpression(tp); in emitIntrinsic()
401 tp = emitIntrinsic2(tp); in emitIntrinsic()
403 emitExpression(tp); in emitIntrinsic()
405 emitExpression(tp); in emitIntrinsic()
411 void emitMethodCall(Type tp) { in emitMethodCall() argument
412 if (tp != kBoolean && !in_inner_) { in emitMethodCall()
427 emitIntrinsic(tp); in emitMethodCall()
432 void emitUnbox(Type tp) { in emitUnbox() argument
434 emitType(tp); in emitUnbox()
436 emitTypeClass(tp); in emitUnbox()
438 emitExpression(tp); in emitUnbox()
443 void emitMisc(Type tp) { in emitMisc() argument
444 if (tp == kBoolean) { in emitMisc()
446 } else if (isInteger(tp)) { in emitMisc()
447 const char* prefix = tp == kLong ? "Long" : "Integer"; in emitMisc()
453 const char* prefix = tp == kDouble ? "Double" : "Float"; in emitMisc()
466 uint32_t adjustLocal(Type tp, int32_t a) { in adjustLocal() argument
467 switch (tp) { in adjustLocal()
507 void emitLiteral(Type tp) { in emitLiteral() argument
508 switch (tp) { in emitLiteral()
518 bool emitArrayVariable(Type tp) { in emitArrayVariable() argument
519 if (tp == array_type_) { in emitArrayVariable()
532 bool emitLocalVariable(Type tp) { in emitLocalVariable() argument
533 uint32_t locals = adjustLocal(tp, 0); in emitLocalVariable()
536 switch (tp) { in emitLocalVariable()
549 void emitFieldVariable(Type tp) { in emitFieldVariable() argument
550 switch (tp) { in emitFieldVariable()
560 void emitVariable(Type tp) { in emitVariable() argument
563 if (emitArrayVariable(tp)) in emitVariable()
567 if (emitLocalVariable(tp)) in emitVariable()
571 emitFieldVariable(tp); in emitVariable()
577 void emitExpression(Type tp) { in emitExpression() argument
581 emitLiteral(tp); in emitExpression()
583 emitVariable(tp); in emitExpression()
594 emitUnaryOp(tp); in emitExpression()
596 emitExpression(tp); in emitExpression()
600 emitIncDecOp(tp); in emitExpression()
601 emitVariable(tp); in emitExpression()
605 emitVariable(tp); in emitExpression()
606 emitIncDecOp(tp); in emitExpression()
612 emitExpression(tp); in emitExpression()
614 emitExpression(tp); in emitExpression()
618 emitTypeConversion(tp); in emitExpression()
622 emitIntrinsic(tp); in emitExpression()
626 emitMethodCall(tp); in emitExpression()
630 emitUnbox(tp); in emitExpression()
634 emitMisc(tp); in emitExpression()
638 emitExpression(tp); in emitExpression()
640 emitBinaryOp(tp); in emitExpression()
642 emitExpression(tp); in emitExpression()
700 Type tp = randomType(); in emitScope() local
704 emitType(tp); in emitScope()
705 switch (tp) { in emitScope()
712 emitExpression(tp); in emitScope()
715 adjustLocal(tp, 1); // local now visible in emitScope()
719 adjustLocal(tp, -1); // local no longer visible in emitScope()
1017 Type tp = randomType(); in emitAssignment() local
1018 emitVariable(tp); in emitAssignment()
1020 emitAssignmentOp(tp); in emitAssignment()
1022 emitExpression(tp); in emitAssignment()
1304 struct timeval tp; in main() local
1305 gettimeofday(&tp, nullptr); in main()
1308 uint32_t seed = (tp.tv_sec * 1000000 + tp.tv_usec); in main()