Skip to content

Commit 36f35ec

Browse files
committed
Remove remaining q uses
Signed-off-by: Theresa Mammarella <Theresa.T.Mammarella@ibm.com>
1 parent d946965 commit 36f35ec

File tree

35 files changed

+37
-110
lines changed

35 files changed

+37
-110
lines changed

debugtools/DDR_VM/src/com/ibm/j9ddr/vm29/j9/SendSlot.java

-3
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,6 @@ public static UDATA getSendSlotsFromSignature(J9UTF8Pointer signature) throws Co
5555
break;
5656
}
5757
case 'L':
58-
/*[IF INLINE-TYPES]*/
59-
case 'Q':
60-
/*[ENDIF] INLINE-TYPES */
6158
for (i++; J9UTF8Helper.stringValue(signature).charAt(i) != ';'; i++);
6259
sendArgs = sendArgs.add(1);
6360
break;

debugtools/DDR_VM/src/com/ibm/j9ddr/vm29/j9/stackwalker/JITStackWalker.java

-6
Original file line numberDiff line numberDiff line change
@@ -553,9 +553,6 @@ private void jitWalkResolveMethodFrame(WalkState walkState) throws CorruptDataEx
553553
while ((sigChar = jitNextSigChar(signatureString)) != ')') {
554554
switch (sigChar) {
555555
case 'L':
556-
/*[IF INLINE-TYPES]*/
557-
case 'Q':
558-
/*[ENDIF] INLINE-TYPES */
559556
if (J9SW_ARGUMENT_REGISTER_COUNT_DEFINED && !stackSpillCount.eq(0)) {
560557
if ((walkState.flags & J9_STACKWALK_ITERATE_O_SLOTS) != 0) {
561558
try {
@@ -633,9 +630,6 @@ private char jitNextSigChar(String signatureString) throws CorruptDataException
633630
/* Fall through to consume type name, utfChar == 'L' for return value */
634631

635632
case 'L':
636-
/*[IF INLINE-TYPES]*/
637-
case 'Q':
638-
/*[ENDIF] INLINE-TYPES */
639633
while (signatureString.charAt(charIndex++) != ';')
640634
;
641635
}

debugtools/DDR_VM/src/com/ibm/j9ddr/vm29/pointer/helper/J9ClassHelper.java

+1-8
Original file line numberDiff line numberDiff line change
@@ -169,9 +169,6 @@ public static String getJavaName(J9ClassPointer clazz) throws CorruptDataExcepti
169169
case 'Z': return "boolean" + aritySuffix;
170170

171171
case 'L':
172-
/*[IF INLINE-TYPES]*/
173-
case 'Q':
174-
/*[ENDIF] INLINE-TYPES */
175172
return getName(arrayClass.leafComponentType()) + aritySuffix;
176173
}
177174

@@ -537,10 +534,6 @@ public static boolean isAnonymousClass(J9ClassPointer clazz) throws CorruptDataE
537534
* @return true if the character indicates the beginning of a reference or value signature, false otherwise
538535
*/
539536
public static boolean isRefOrValSignature(char firstChar) {
540-
return firstChar == 'L'
541-
/*[IF INLINE-TYPES]*/
542-
|| (firstChar == 'Q')
543-
/*[ENDIF] INLINE-TYPES */
544-
;
537+
return firstChar == 'L';
545538
}
546539
}

debugtools/DDR_VM/src/com/ibm/j9ddr/vm29/pointer/helper/J9IndexableObjectHelper.java

-9
Original file line numberDiff line numberDiff line change
@@ -397,9 +397,6 @@ public static void getData(J9IndexableObjectPointer objPointer, Object dst, int
397397
}
398398

399399
case 'L':
400-
/*[IF INLINE-TYPES]*/
401-
case 'Q':
402-
/*[ENDIF] INLINE-TYPES */
403400
case '[':
404401
{
405402
if (!(dst instanceof J9ObjectPointer[])) {
@@ -570,9 +567,6 @@ public static Object getData(J9IndexableObjectPointer objPointer) throws Corrupt
570567
}
571568

572569
case 'L':
573-
/*[IF INLINE-TYPES]*/
574-
case 'Q':
575-
/*[ENDIF] INLINE-TYPES */
576570
case '[':
577571
{
578572
J9ObjectPointer[] data = new J9ObjectPointer[arraySize];
@@ -649,9 +643,6 @@ public static String getDataAsString(J9IndexableObjectPointer array, int dumpLim
649643
break;
650644

651645
case 'L':
652-
/*[IF INLINE-TYPES]*/
653-
case 'Q':
654-
/*[ENDIF] INLINE-TYPES */
655646
case '[':
656647
{
657648
J9ObjectPointer item = ((J9ObjectPointer[]) data)[i];

debugtools/DDR_VM/src/com/ibm/j9ddr/vm29/tools/ddrinteractive/commands/J9StaticsCommand.java

-3
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,6 @@ public void run(String command, String[] args, Context context, PrintStream out)
8484

8585
switch (sig.charAt(0)) {
8686
case 'L':
87-
/*[IF INLINE-TYPES]*/
88-
case 'Q':
89-
/*[ENDIF] INLINE-TYPES */
9087
case '[':
9188
CommandUtils.dbgPrint(out, "\t%s %s %s (!j9romstaticfieldshape %s) = !j9object %s\n",
9289
fieldAddress.getHexAddress(), name, sig, field.getHexAddress(), fieldAddress.at(0).getHexValue());

debugtools/DDR_VM/src/com/ibm/j9ddr/vm29/tools/ddrinteractive/structureformat/extensions/J9ObjectStructureFormatter.java

-3
Original file line numberDiff line numberDiff line change
@@ -221,9 +221,6 @@ private void formatArrayObject(PrintStream out, J9ClassPointer localClazz, U8Poi
221221
}
222222
break;
223223
case 'L':
224-
/*[IF INLINE-TYPES]*/
225-
case 'Q':
226-
/*[ENDIF] INLINE-TYPES */
227224
case '[':
228225
if (ValueTypeHelper.getValueTypeHelper().isJ9ClassIsFlattened(localClazz)) {
229226
formatFlattenedObjectArray(out, tabLevel, begin, finish, array);

jcl/src/java.base/share/classes/java/lang/invoke/MethodTypeHelper.java

+5-17
Original file line numberDiff line numberDiff line change
@@ -185,17 +185,13 @@ static String getBytecodeStringName(Class<?> c) {
185185
/*
186186
* Convert the string from bytecode format to the format needed for ClassLoader#loadClass().
187187
* Change all '/' to '.'.
188-
* Remove the 'L', 'Q', and ';' from objects, unless they are array classes.
188+
* Remove the 'L' and ';' from objects, unless they are array classes.
189189
*/
190190
private static final Class<?> nonPrimitiveClassFromString(String name, ClassLoader classLoader) {
191191
try {
192192
name = name.replace('/', '.');
193-
if ((name.charAt(0) == 'L')
194-
/*[IF INLINE-TYPES]*/
195-
|| (name.charAt(0) == 'Q')
196-
/*[ENDIF] INLINE-TYPES */
197-
) {
198-
// Remove the 'L'/'Q' and ';'.
193+
if (name.charAt(0) == 'L') {
194+
// Remove the 'L' and ';'.
199195
name = name.substring(1, name.length() - 1);
200196
}
201197
return Class.forName(name, false, classLoader);
@@ -212,21 +208,13 @@ static final int parseIntoClass(char[] signature, int index, ArrayList<Class<?>>
212208
char current = signature[index];
213209
Class<?> c;
214210

215-
if ((current == 'L') || (current == '[')
216-
/*[IF INLINE-TYPES]*/
217-
|| (current == 'Q')
218-
/*[ENDIF] INLINE-TYPES */
219-
) {
211+
if ((current == 'L') || (current == '[')) {
220212
int start = index;
221213
while(signature[index] == '[') {
222214
index++;
223215
}
224216
String name;
225-
if ((signature[index] != 'L')
226-
/*[IF INLINE-TYPES]*/
227-
&& (signature[index] != 'Q')
228-
/*[ENDIF] INLINE-TYPES */
229-
) {
217+
if (signature[index] != 'L') {
230218
name = descriptor.substring(start, index + 1);
231219
} else {
232220
int end = descriptor.indexOf(';', index);

runtime/codert_vm/thunkcrt.c

+1-7
Original file line numberDiff line numberDiff line change
@@ -361,9 +361,7 @@ j9ThunkIterateAndEncode(char ** signatureDataPtr, U_8 ** encodedTypesPtr, U_8 *
361361
while ((c = *signatureData++) == '[') ;
362362
/* intentional fall-through */
363363
case 'L':
364-
/* intentional fall-through */
365-
case 'Q':
366-
if ((c == 'L') || (c == 'Q')) {
364+
if (c == 'L') {
367365
while (*signatureData++ != ';') ;
368366
}
369367
#if defined(J9VM_ENV_DATA64)
@@ -503,8 +501,6 @@ j9ThunkVMHelperFromSignature(void * jitConfig, UDATA signatureLength, char *sign
503501
case '[':
504502
/* intentional fall-through */
505503
case 'L':
506-
/* intentional fall-through */
507-
case 'Q':
508504
#if defined(J9VM_ENV_DATA64)
509505
helper = J9_BUILDER_SYMBOL(icallVMprJavaSendVirtualL);
510506
break;
@@ -540,8 +536,6 @@ j9ThunkInvokeExactHelperFromSignature(void * jitConfig, UDATA signatureLength, c
540536
case '[':
541537
/* intentional fall-through */
542538
case 'L':
543-
/* intentional fall-through */
544-
case 'Q':
545539
helper = J9_BUILDER_SYMBOL(icallVMprJavaSendInvokeExactL);
546540
break;
547541
default:

runtime/compiler/control/JITServerHelpers.cpp

-2
Original file line numberDiff line numberDiff line change
@@ -1526,8 +1526,6 @@ JITServerHelpers::getFullClassName(uint8_t *name, uint32_t length, const J9ROMCl
15261526
uint32_t baseNameLength = J9UTF8_LENGTH(baseName);
15271527

15281528
// Build the array class signature that will be passed to jitGetClassInClassloaderFromUTF8() on the client.
1529-
// Note that for object arrays we can simply use the "L" type signature since the distinction with "Q" types
1530-
// is ignored during array class lookup by name (see internalFindArrayClass() in runtime/vm/classsupport.c).
15311529
uint32_t i;
15321530
for (i = 0; i < numDimensions; ++i)
15331531
name[i] = '[';

runtime/compiler/env/J2IThunk.cpp

-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,6 @@ char TR_MHJ2IThunkTable::terseTypeChar(char *type)
111111
{
112112
case '[':
113113
case 'L':
114-
case 'Q':
115114
return TR::Compiler->target.is64Bit()? 'L' : 'I';
116115
case 'Z':
117116
case 'B':

runtime/compiler/env/J2IThunk.hpp

+1-2
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,7 @@ class TR_MHJ2IThunkTable
7272
case 'J': return TC_LONG;
7373
case 'F': return TC_FLOAT;
7474
case 'D': return TC_DOUBLE;
75-
case 'L':
76-
case 'Q': return TC_REFERENCE;
75+
case 'L': return TC_REFERENCE;
7776
default:
7877
TR_ASSERT(0, "Unknown type char '%c'", typeChar);
7978
return -1;

runtime/compiler/env/J9ClassEnv.cpp

-1
Original file line numberDiff line numberDiff line change
@@ -606,7 +606,6 @@ static void addEntryForFieldImpl(TR_VMField *field, TR::TypeLayoutBuilder &tlb,
606606
break;
607607
}
608608
case 'L':
609-
case 'Q':
610609
case '[':
611610
{
612611
dataType = TR::Address;

runtime/compiler/env/J9ClassEnv.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ class OMR_EXTENSIBLE ClassEnv : public OMR::ClassEnvConnector
128128
* Checks whether a class supports direct memory comparison if its fields meet
129129
* the criteria that NO field is of
130130
* - type double (D) or float (F)
131-
* - nullable-class/interface type (L)
132-
* - null-free class type (Q) that are not both flattened and recursively
131+
* - nullable-class/interface type
132+
* - null restricted class type that are not both flattened and recursively
133133
* compatible for direct memory comparison
134134
*
135135
* \param clazz

runtime/compiler/env/VMJ9.cpp

+2-3
Original file line numberDiff line numberDiff line change
@@ -4564,7 +4564,6 @@ TR_J9VMBase::lookupMethodHandleThunkArchetype(uintptr_t methodHandle)
45644564
{
45654565
case '[':
45664566
case 'L':
4567-
case 'Q':
45684567
// The thunkable signature might return some other class, but archetypes
45694568
// returning a reference are always declared to return Object.
45704569
//
@@ -7344,10 +7343,10 @@ TR_J9VM::getClassFromSignature(const char * sig, int32_t sigLength, J9ConstantPo
73447343
J9Class * j9class = NULL;
73457344
TR_OpaqueClassBlock * returnValue = NULL;
73467345

7347-
// For a non-array class type, strip off the first 'L' or 'Q' and last ';' of the
7346+
// For a non-array class type, strip off the first 'L' and last ';' of the
73487347
// signature
73497348
//
7350-
if ((*sig == 'L' || *sig == 'Q') && sigLength > 2)
7349+
if ((*sig == 'L') && sigLength > 2)
73517350
{
73527351
sig += 1;
73537352
sigLength -= 2;

runtime/compiler/env/annotations/AnnotationBase.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ void TR_AnnotationBase::loadExpectedAnnotationClasses(J9VMThread * vmThread)
7878
acquireVMAccess(vmThread); // this is not the comp thread so suspension is possible
7979
for(i=0;i < kLastAnnotationSignature;++i)
8080
{
81-
// Strip off 'L' prefix or 'Q' prefix and ';' suffix
81+
// Strip off 'L' prefix and ';' suffix
8282
const char *name = recognizedAnnotations[i].name;
8383
int32_t nameLen = recognizedAnnotations[i].nameLen;
8484
TR_ASSERT(strlen(name) == nameLen,"Table entry for %s is %d but should be %d\n",name,nameLen,strlen(name));
@@ -251,7 +251,7 @@ TR_AnnotationBase::getDefaultAnnotationInfo(const char *annotationName)
251251
}
252252
}
253253
if(NULL == clazz) return NULL;
254-
const char * className = annotationName+1; // strip off leading 'L' or 'Q';
254+
const char * className = annotationName+1; // strip off leading 'L';
255255
int32_t classNameLength = strlen (className) -1; // strip off trailing ';'
256256
J9AnnotationInfoEntry *defaultEntry = intFunc->getAnnotationDefaultsForNamedAnnotation(vmThread, clazz, (char *)className, classNameLength,
257257
J9_FINDCLASS_FLAG_EXISTING_ONLY);

runtime/compiler/env/j9fieldsInfo.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636

3737
static int isReferenceSignature(char *signature)
3838
{
39-
return ( (signature[0] == 'L' ) || (signature[0] == '[') || (signature[0] == 'Q'));
39+
return ( (signature[0] == 'L' ) || (signature[0] == '['));
4040
}
4141

4242
int TR_VMField::isReference()

runtime/compiler/env/j9method.cpp

+8-14
Original file line numberDiff line numberDiff line change
@@ -7489,9 +7489,9 @@ TR_ResolvedJ9Method::makeParameterList(TR::ResolvedMethodSymbol *methodSym)
74897489
}
74907490

74917491
// Walk to the end of the class name, if this is a class name
7492-
if (*end == 'L' || *end == 'Q')
7492+
if (*end == 'L')
74937493
{
7494-
// Assume the form is L<classname> or Q<classname>; where <classname> is
7494+
// Assume the form is L<classname>; where <classname> is
74957495
// at least 1 char and therefore skip the first 2 chars
74967496
end += 2;
74977497
end = (char *)memchr(end, ';', sigEnd - end);
@@ -7670,15 +7670,15 @@ TR_J9MethodParameterIterator::TR_J9MethodParameterIterator(TR_J9MethodBase &j9Me
76707670

76717671
TR::DataType TR_J9MethodParameterIterator::getDataType()
76727672
{
7673-
if (*_sig == 'L' || *_sig == '[' || *_sig == 'Q')
7673+
if (*_sig == 'L' || *_sig == '[')
76747674
{
76757675
_nextIncrBy = 0;
76767676
while (_sig[_nextIncrBy] == '[')
76777677
{
76787678
++_nextIncrBy;
76797679
}
76807680

7681-
if (_sig[_nextIncrBy] != 'L' && _sig[_nextIncrBy] != 'Q')
7681+
if (_sig[_nextIncrBy] != 'L')
76827682
{
76837683
// Primitive array
76847684
++_nextIncrBy;
@@ -7735,7 +7735,7 @@ TR::DataType TR_J9MethodParameterIterator::getDataType()
77357735
TR_OpaqueClassBlock * TR_J9MethodParameterIterator::getOpaqueClass()
77367736
{
77377737
TR_J9VMBase *fej9 = (TR_J9VMBase *)(_comp.fe());
7738-
TR_ASSERT(*_sig == '[' || *_sig == 'L' || *_sig == 'Q', "Asked for class of incorrect Java parameter.");
7738+
TR_ASSERT(*_sig == '[' || *_sig == 'L', "Asked for class of incorrect Java parameter.");
77397739
if (_nextIncrBy == 0) getDataType();
77407740
return _resolvedMethod == NULL ? NULL :
77417741
fej9->getClassFromSignature(_sig, _nextIncrBy, _resolvedMethod);
@@ -7754,7 +7754,7 @@ bool TR_J9MethodParameterIterator::isArray()
77547754

77557755
bool TR_J9MethodParameterIterator::isClass()
77567756
{
7757-
return (*_sig == 'L' || *_sig == 'Q');
7757+
return (*_sig == 'L');
77587758
}
77597759

77607760
bool TR_J9MethodParameterIterator::atEnd()
@@ -7804,7 +7804,6 @@ static TR::DataType typeFromSig(char sig)
78047804
{
78057805
case 'L':
78067806
case '[':
7807-
case 'Q':
78087807
return TR::Address;
78097808
case 'I':
78107809
case 'Z':
@@ -8028,7 +8027,6 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
80288027
const char *targetName = targetBuf; const char *targetType = targetBuf;
80298028
switch (sourceSig[0])
80308029
{
8031-
case 'Q':
80328030
case 'L':
80338031
case '[':
80348032
sourceName = "object";
@@ -8040,7 +8038,6 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
80408038
}
80418039
switch (targetSig[0])
80428040
{
8043-
case 'Q':
80448041
case 'L':
80458042
case '[':
80468043
targetName = "object";
@@ -8056,7 +8053,7 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
80568053
if (strcmp(sourceType, targetType))
80578054
{
80588055
char methodName[30], methodSignature[50];
8059-
if ((sourceType[0] == 'L' || sourceType[0] == 'Q') && isExplicit)
8056+
if ((sourceType[0] == 'L') && isExplicit)
80608057
sprintf(methodName, "explicitObject2%s", targetName);
80618058
else
80628059
sprintf(methodName, "%s2%s", sourceName, targetName);
@@ -8077,7 +8074,7 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
80778074

80788075
// Address conversions need a downcast after the call
80798076
//
8080-
if (targetType[0] == 'L' || targetType[0] == 'Q')
8077+
if (targetType[0] == 'L')
80818078
{
80828079
uintptr_t methodHandle;
80838080
uintptr_t sourceArguments;
@@ -8244,7 +8241,6 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
82448241
break;
82458242
case 'L':
82468243
case '[':
8247-
case 'Q':
82488244
callOp = TR::acalli;
82498245
break;
82508246
case 'V':
@@ -8382,7 +8378,6 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
83828378
{
83838379
case 'L':
83848380
case '[':
8385-
case 'Q':
83868381
sprintf(extraName, "extra_L");
83878382
extraSignature = artificialSignature(stackAlloc, "(L" JSR292_ArgumentMoverHandle ";I)Ljava/lang/Object;");
83888383
break;
@@ -8466,7 +8461,6 @@ TR_J9ByteCodeIlGenerator::runFEMacro(TR::SymbolReference *symRef)
84668461
{
84678462
case 'L':
84688463
case '[':
8469-
case 'Q':
84708464
sprintf(extraName, "extra_L");
84718465
extraSignature = artificialSignature(stackAlloc, "(L" JSR292_ArgumentMoverHandle ";I)Ljava/lang/Object;");
84728466
break;

runtime/compiler/env/j9method.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ inline const char *nextSignatureArgument(const char *currentArgument)
7272
const char *result = currentArgument;
7373
while (*result == '[')
7474
result++;
75-
if (*result == 'L' || *result == 'Q')
75+
if (*result == 'L')
7676
while (*result != ';')
7777
result++;
7878
return result+1;

0 commit comments

Comments
 (0)