mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-07 12:42:54 +08:00
Fix resource destruction scheme on device closure.
- Call waitForTaskCountAndCleanAllocationList with latest flushed task count to reflect what was actually sent to HW. - refactor cleanAllocationList to waitForTaskCountAndCleanAllocationList Change-Id: I5301185c5fce212e39eb017b952b43c279559cf4
This commit is contained in:
committed by
sys_ocldev
parent
42798fcae0
commit
af77720f9c
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, Intel Corporation
|
||||
* Copyright (c) 2018, Intel Corporation
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and associated documentation files (the "Software"),
|
||||
@@ -909,7 +909,7 @@ TEST_F(EventTests, waitForEventsDestroysTemporaryAllocations) {
|
||||
|
||||
MemoryManager *memoryManager = csr.getMemoryManager();
|
||||
//kill some temporary objects that fixture creates.
|
||||
csr.cleanAllocationList(-1, TEMPORARY_ALLOCATION);
|
||||
csr.waitForTaskCountAndCleanAllocationList(-1, TEMPORARY_ALLOCATION);
|
||||
|
||||
EXPECT_TRUE(memoryManager->graphicsAllocations.peekIsEmpty());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user