Media (Intel® oneAPI Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools from Intel. This includes Intel® oneAPI Video Processing Library and Intel® Media SDK.
2971 Discussions

H264 Encoding Memory leak with latest HD Graphics 510 driver

Iyer__Ralph
Beginner
1,221 Views

 

System Info:

Processor: Intel Celeron 3955U @2.00 GHZ

Graphics Driver: Intel HD Graphics 510 (15.40.25.4463)

Operating System: Windows 7 - 64 bit

Intel Media SDK Version: 2016 - R2

Problem:  A memory leak has been observed while using encoding (h264) frames with the the latest driver (15.40.25.4463) driver.   The current beta driver also has the memory leak (15.40.26.4474)

I tried previously released drivers and can confirm that the 15.40.10.4300 driver does not have the memory leak.  The memory leak seems be introduced in 15.40.22.4424 and still exist in newer drivers.

Steps to reproduce:

Encode a relatively input large file (> 30 GB) with the sample_encode.exe utility and observer memory usage in task manager:

sample_encode.exe h264 -i input.yuv -o output.264 -w 1920 -h 1080

Note: A large input file is used to prevent the sample_encode utility from ending quickly.

With 15.40.25.4463, the memory usage steadily increases.  On the other hand, with 15.40.10.4300 memory usage is stable.

 

0 Kudos
25 Replies
Ivan_W_1
Beginner
124 Views

Thanks Brent - I did a longer test and found after some initial memory growth in the area, it settled down and I don't see the same problem anymore with latest. 4542

Tomhi
Beginner
124 Views

Hi,

I reproduced the same problem under the following environment.

Intel(R) Media Server Studio 2017 - System Analyzer (64-bit)


The following versions of Media SDK API are supported by platform/driver
[opportunistic detection of MSDK API > 1.23]:

        Version Target  Supported       Dec     Enc
        1.0     HW      Yes             X       X
        1.0     SW      No
        1.1     HW      Yes             X       X
        1.1     SW      No
        1.2     HW      Yes             X       X
        1.2     SW      No
        1.3     HW      Yes             X       X
        1.3     SW      No
        1.4     HW      Yes             X       X
        1.4     SW      No
        1.5     HW      Yes             X       X
        1.5     SW      No
        1.6     HW      Yes             X       X
        1.6     SW      No
        1.7     HW      Yes             X       X
        1.7     SW      No
        1.8     HW      Yes             X       X
        1.8     SW      No
        1.9     HW      Yes             X       X
        1.9     SW      No
        1.10    HW      Yes             X       X
        1.10    SW      No
        1.11    HW      Yes             X       X
        1.11    SW      No
        1.12    HW      Yes             X       X
        1.12    SW      No
        1.13    HW      Yes             X       X
        1.13    SW      No
        1.14    HW      Yes             X       X
        1.14    SW      No
        1.15    HW      Yes             X       X
        1.15    SW      No
        1.16    HW      Yes             X       X
        1.16    SW      No
        1.17    HW      Yes             X       X
        1.17    SW      No
        1.18    HW      Yes             X       X
        1.18    SW      No
        1.19    HW      Yes             X       X
        1.19    SW      No
        1.20    HW      Yes             X       X
        1.20    SW      No
        1.21    HW      Yes             X       X
        1.21    SW      No
        1.22    HW      Yes             X       X
        1.22    SW      No
        1.23    HW      Yes             X       X
        1.23    SW      No
        1.24    HW      Yes             X       X
        1.24    SW      No
        1.25    HW      Yes             X       X
        1.25    SW      No

Graphics Devices:
        Name                                         Version             State
        Intel(R) HD Graphics 620                     23.20.16.4901       Active

System info:
        CPU:    Intel(R) Core(TM) i3-7100U CPU @ 2.40GHz
        OS:     Microsoft Windows 10 Pro
        Arch:   64 ???

Installed Media SDK packages (be patient...processing takes some time):

Installed Media SDK DirectShow filters:

Installed Intel Media Foundation Transforms:
        Intel(R) Hardware M-JPEG Decoder MFT : {00C69F81-0524-48C0-A353-4DD9D54F9A6E}
        Intel(R) Quick Sync Video H.264 Encoder MFT : {4BE8D3C0-0515-4A37-AD55-E4BAE19AF471}
        Intel(R) Hardware H265 Encoder MFT : {BC10864D-2B34-408F-912A-102B1B867B6C}

The memory leaking speed is 90MB/hour.

I tried to call MFXVideoSession::Close () again to restart the encoding by MFXVideoSession::Init () again to avoid this problem.
However, this workaround was not effective. Because the following problem occurred.
https://software.intel.com/en-us/forums/intel-media-sdk/topic/600643

Is there any good means?

Tomhi
Beginner
124 Views

I have a problem that h264-encoding speed become slower as well as a memory leak.
At the begining, the encoding speed is 500 frames/sec.
And 50 minutes after, it becomes 80 frames/sec.

You can reproduce these problems with sample_encode.exe of the Intel Media SDK samples( https://github.com/Intel-Media-SDK/samples ).

Running Environment:
   Processor  : Intel(R) Core(TM) i3-7100U @ 2.40GHz
   RAM        : 8.00GB
   OS         : Microsoft Windows 10 Pro 64bit
   Driver     : Intel HD Graphics 620 ver.23.20.16.4901
   SDK Version: 2017R1 (Ver.7.0.0.487)
   Input Data : yuv file (resolution: 960x554 from H.264.1 comformance test data)
   Command    : h264 -i <input file path> -o <output file path> -h 544 -w 960 -hw

 

Tomhi
Beginner
124 Views

But, when I updated the driver I got it fixed.
The following tables illustrate memory usages of an h264 encoding program on the latest driver (ver.23.20.16.4944) and the previous driver (ver.23.20.16.4901).

* HD Graphics 610 driver ver.23.20.16.4944, 2018-02-13
| Elapsed Time | Memory Usage |
|            0 |         60MB |
|   50 minutes |         53MB |

* HD Graphics 610 driver ver.23.20.16.4901, 2017-12-28
| Elapsed Time | Memory Usage |
|            0 |         60MB |
|   50 minutes |        130MB |


Did you just fix it?

hiramatsu__seiki
Beginner
124 Views

Hello,

I am not good at English, as I am not an English speaker.
For this reason, please forgive my difficult to read sentences.

When using the software we created, we checked the memory 
leak with the following PCs.

(1)
Processor: Intel Core i5-4200 @1.60 GHZ

Graphics Driver: Intel HD Graphics 4400 (10.18.10.3355)

Operating System: Windows 8.1 - 64 bit

Intel Media SDK Version: 2017 - R1

(2)
Processor: Intel Core i5-3220M @2.6GHz

Graphics Driver: Intel HD Graphics 4000 (10.18.10.4425)

Operating System: Windows 10 - 64 bit

Intel Media SDK Version: 2017 - R1

(3)
rocessor: Intel Core i5-6300U @2.40 GHZ

Graphics Driver: Intel HD Graphics 520 (21.20.16.4627)

Operating System: Windows 10 - 64 bit

Intel Media SDK Version: 2017 - R1


(1) did not leak memory, but memory leak occurred 
in (2) and (3).

We think that Graphics Driver is the cause, is it correct?
(Is it the same as the cause of this thread?)

Will it be solved if we update the version to the latest 
version of the driver?

Someone is very helpful if you give us advice.

Best regards,

Seiki

Reply