Skip to content

Commit 58c1275

Browse files
authored
Merge pull request #21851 from mpirvu/setcallcount-cleanup
Delete isWarmCallGraphCall() and other unused related methods
2 parents b0fe5ec + 0795434 commit 58c1275

File tree

6 files changed

+0
-49
lines changed

6 files changed

+0
-49
lines changed

runtime/compiler/env/VMJ9.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5932,16 +5932,6 @@ TR_J9VMBase::setIProfilerCallCount(TR_OpaqueMethodBlock *caller, int32_t bcIndex
59325932
profiler->setCallCount(caller, bcIndex, count, comp);
59335933
}
59345934

5935-
int32_t
5936-
TR_J9VMBase::getCGEdgeWeight(TR::Node *callerNode, TR_OpaqueMethodBlock *callee, TR::Compilation *comp)
5937-
{
5938-
TR_IProfiler *profiler = getIProfiler();
5939-
if (profiler)
5940-
return profiler->getCGEdgeWeight(callerNode, callee, comp);
5941-
5942-
return 0;
5943-
}
5944-
59455935
bool
59465936
TR_J9VMBase::isCallGraphProfilingEnabled()
59475937
{

runtime/compiler/env/VMJ9.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1217,7 +1217,6 @@ class TR_J9VMBase : public TR_FrontEnd
12171217
uint32_t *getAllocationProfilingDataPointer(TR_ByteCodeInfo &bcInfo, TR_OpaqueClassBlock *clazz, TR_OpaqueMethodBlock *method, TR::Compilation *comp);
12181218
uint32_t *getGlobalAllocationDataPointer();
12191219
virtual TR_ExternalProfiler *hasIProfilerBlockFrequencyInfo(TR::Compilation& comp);
1220-
virtual int32_t getCGEdgeWeight(TR::Node *callerNode, TR_OpaqueMethodBlock *callee, TR::Compilation *comp);
12211220
virtual int32_t getIProfilerCallCount(TR_OpaqueMethodBlock *caller, int32_t bcIndex, TR::Compilation *);
12221221
virtual int32_t getIProfilerCallCount(TR_OpaqueMethodBlock *callee, TR_OpaqueMethodBlock *caller, int32_t bcIndex, TR::Compilation *);
12231222
virtual void setIProfilerCallCount(TR_OpaqueMethodBlock *caller, int32_t bcIndex, int32_t count, TR::Compilation *);

runtime/compiler/runtime/IProfiler.cpp

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3429,24 +3429,6 @@ TR_IProfiler::getCallCount(TR_ByteCodeInfo &bcInfo, TR::Compilation *comp)
34293429
return getCallCount(getMethodFromBCInfo(bcInfo, comp), (int32_t)bcInfo.getByteCodeIndex(), comp);
34303430
}
34313431

3432-
int32_t
3433-
TR_IProfiler::getCGEdgeWeight (TR::Node *callerNode, TR_OpaqueMethodBlock *callee, TR::Compilation *comp)
3434-
{
3435-
TR_ByteCodeInfo& bcInfo = callerNode->getByteCodeInfo();
3436-
uintptr_t thisPC = getSearchPC (getMethodFromNode(callerNode, comp), bcInfo.getByteCodeIndex(), comp);
3437-
3438-
if (isSpecialOrStatic(*(U_8 *)thisPC))
3439-
return getCallCount(bcInfo, comp);
3440-
3441-
TR_IPBCDataCallGraph *cgData = getCGProfilingData(callerNode->getByteCodeInfo(), comp);
3442-
if (cgData)
3443-
{
3444-
return cgData->getEdgeWeight((TR_OpaqueClassBlock *)J9_CLASS_FROM_METHOD(((J9Method *)callee)), comp);
3445-
}
3446-
return 0;
3447-
}
3448-
3449-
34503432
int32_t
34513433
TR_IProfiler::getMaxCallCount()
34523434
{

runtime/compiler/runtime/IProfiler.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -676,7 +676,6 @@ class TR_IProfiler : public TR_ExternalProfiler
676676
int32_t getCallCount(TR_ByteCodeInfo &bcInfo, TR::Compilation *comp);
677677
virtual void setCallCount(TR_OpaqueMethodBlock *method, int32_t bcIndex, int32_t count, TR::Compilation *);
678678

679-
int32_t getCGEdgeWeight (TR::Node *callerNode, TR_OpaqueMethodBlock *callee, TR::Compilation *comp);
680679
bool isCallGraphProfilingEnabled();
681680

682681
virtual TR_AbstractInfo *createIProfilingValueInfo( TR_ByteCodeInfo &bcInfo, TR::Compilation *comp);

runtime/compiler/runtime/J9Profiler.cpp

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -959,12 +959,6 @@ TR_ValueProfileInfoManager::getCallGraphProfilingCount(TR_OpaqueMethodBlock *cal
959959
return comp->fej9()->getIProfilerCallCount(calleeMethod, method, byteCodeIndex, comp);
960960
}
961961

962-
int32_t
963-
TR_ValueProfileInfoManager::getCallGraphProfilingCount(TR::Node *node, TR_OpaqueMethodBlock *method, TR::Compilation *comp)
964-
{
965-
return comp->fej9()->getCGEdgeWeight(node, method, comp);
966-
}
967-
968962
int32_t
969963
TR_ValueProfileInfoManager::getCallGraphProfilingCount(TR::Node *node, TR::Compilation *comp)
970964
{
@@ -1034,17 +1028,6 @@ TR_ValueProfileInfoManager::getAdjustedInliningWeight(TR::Node *callNode, int32_
10341028
return callGraphAdjustedWeight;
10351029
}
10361030

1037-
bool
1038-
TR_ValueProfileInfoManager::isWarmCallGraphCall(TR::Node *node, TR_OpaqueMethodBlock *method, TR::Compilation *comp)
1039-
{
1040-
if (node->getSymbolReference() && node->getSymbolReference()->getSymbol() &&
1041-
((node->getSymbolReference()->getSymbol()->castToMethodSymbol()->getMethodKind()==TR::MethodSymbol::Special) ||
1042-
(node->getSymbolReference()->getSymbol()->castToMethodSymbol()->getMethodKind()==TR::MethodSymbol::Static)))
1043-
return false;
1044-
1045-
return (getCallGraphProfilingCount(node, method, comp) < comp->getFlowGraph()->getLowFrequency());
1046-
}
1047-
10481031
bool
10491032
TR_ValueProfileInfoManager::isCallGraphProfilingEnabled(TR::Compilation *comp)
10501033
{

runtime/compiler/runtime/J9Profiler.hpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -575,10 +575,8 @@ class TR_ValueProfileInfoManager
575575
bool isColdCall(TR_OpaqueMethodBlock *method, int32_t byteCodeIndex, TR::Compilation *comp);
576576
bool isColdCall(TR_OpaqueMethodBlock *calleeMethod, TR_OpaqueMethodBlock *method, int32_t byteCodeIndex, TR::Compilation *comp);
577577
bool isColdCall(TR::Node *node, TR::Compilation *comp);
578-
bool isWarmCallGraphCall(TR::Node *node, TR_OpaqueMethodBlock *method, TR::Compilation *comp);
579578
bool isWarmCall(TR::Node *node, TR::Compilation *comp);
580579
bool isCallGraphProfilingEnabled(TR::Compilation *comp);
581-
int32_t getCallGraphProfilingCount(TR::Node *node, TR_OpaqueMethodBlock *method, TR::Compilation *comp);
582580
int32_t getCallGraphProfilingCount(TR::Node *node, TR::Compilation *comp);
583581
int32_t getCallGraphProfilingCount(TR_OpaqueMethodBlock *method, int32_t byteCodeIndex, TR::Compilation *comp);
584582
int32_t getCallGraphProfilingCount(TR_OpaqueMethodBlock *calleeMethod, TR_OpaqueMethodBlock *method, int32_t byteCodeIndex, TR::Compilation *comp);

0 commit comments

Comments
 (0)