[td-11818] opt
This commit is contained in:
parent
53fe1e4f72
commit
b4c898197b
|
@ -5711,6 +5711,7 @@ void addToDiskbasedBuf(SOrderOperatorInfo* pInfo, jmp_buf env) {
|
||||||
assert(size <= getBufPageSize(pInfo->pSortInternalBuf));
|
assert(size <= getBufPageSize(pInfo->pSortInternalBuf));
|
||||||
|
|
||||||
blockDataToBuf(pPage->data, p);
|
blockDataToBuf(pPage->data, p);
|
||||||
|
releaseResBufPage(pInfo->pSortInternalBuf, pPage);
|
||||||
|
|
||||||
blockDataDestroy(p);
|
blockDataDestroy(p);
|
||||||
start = stop + 1;
|
start = stop + 1;
|
||||||
|
|
|
@ -262,7 +262,7 @@ TEST(testCase, external_sort_Test) {
|
||||||
|
|
||||||
int32_t total = 1;
|
int32_t total = 1;
|
||||||
|
|
||||||
// while(1) {
|
while(1) {
|
||||||
int64_t s = taosGetTimestampUs();
|
int64_t s = taosGetTimestampUs();
|
||||||
pRes = pOperator->exec(pOperator, &newgroup);
|
pRes = pOperator->exec(pOperator, &newgroup);
|
||||||
|
|
||||||
|
@ -270,16 +270,16 @@ TEST(testCase, external_sort_Test) {
|
||||||
printf("---------------elapsed:%ld\n", e - s);
|
printf("---------------elapsed:%ld\n", e - s);
|
||||||
|
|
||||||
if (pRes == NULL) {
|
if (pRes == NULL) {
|
||||||
// break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
SColumnInfoData* pCol1 = static_cast<SColumnInfoData*>(taosArrayGet(pRes->pDataBlock, 0));
|
// SColumnInfoData* pCol1 = static_cast<SColumnInfoData*>(taosArrayGet(pRes->pDataBlock, 0));
|
||||||
SColumnInfoData* pCol2 = static_cast<SColumnInfoData*>(taosArrayGet(pRes->pDataBlock, 1));
|
// SColumnInfoData* pCol2 = static_cast<SColumnInfoData*>(taosArrayGet(pRes->pDataBlock, 1));
|
||||||
for (int32_t i = 0; i < pRes->info.rows; ++i) {
|
// for (int32_t i = 0; i < pRes->info.rows; ++i) {
|
||||||
char* p = colDataGet(pCol2, i);
|
// char* p = colDataGet(pCol2, i);
|
||||||
// printf("%d: %d, %s\n", total++, ((int32_t*)pCol1->pData)[i], (char*)varDataVal(p));
|
// printf("%d: %d, %s\n", total++, ((int32_t*)pCol1->pData)[i], (char*)varDataVal(p));
|
||||||
}
|
// }
|
||||||
// }
|
}
|
||||||
|
|
||||||
pOperator->cleanupFn(pOperator->info, 2);
|
pOperator->cleanupFn(pOperator->info, 2);
|
||||||
tfree(exp);
|
tfree(exp);
|
||||||
|
|
Loading…
Reference in New Issue