high CPU usage using omxh264enc on TK1

Hi DaneLLL,

Thank you for your reply, we have a test on the TK1, enable all of CPU to high performance mode, and run same gstreamer command with same video file, but the CPU consuming is higher than what you showed (23%). we are sue there is no other apps running at the same time.

sudo gst-launch-1.0 -e filesrc location=Bourne_Trailer.mp4 ! qtdemux ! h264parse ! omxh264dec ! nvvidconv ! 'video/x-raw(memory:NVMM),format=(string)I420' ! omxh264enc insert-sps-pps=true ! 'video/x-h264, stream-format=(string)byte-stream, profile=high' ! h264parse ! filesink location=out.h264            
Setting pipeline to PAUSED ...
Inside NvxLiteH264DecoderLowLatencyInitNvxLiteH264DecoderLowLatencyInit set DPB and MjstreamingPipeline is PREROLLING ...
NvMMLiteOpen : Block : BlockType = 261 
TVMR: NvMMLiteTVMRDecBlockOpen: 4937: NvMMLiteBlockOpen 
NvMMLiteBlockCreate : Block : BlockType = 261 
TVMR: cbBeginSequence: 571: BeginSequence  1920x816, bVPR = 0
TVMR: cbBeginSequence: 813: DecodeBuffers = 2 
TVMR: cbBeginSequence: 833: Display Resolution : (1920x816) 
TVMR: cbBeginSequence: 834: Display Aspect Ratio : (1920x816) 
TVMR: cbBeginSequence: 998: SurfaceLayout = 3
TVMR: cbBeginSequence: 1028: NumOfSurfaces = 6, InteraceStream = 0, InterlaceEnabled = 0, bSecure = 0, MVC = 0 Semiplanar = 1, bReinit = 1 
Allocating new output: 1920x816 (x 8), ThumbnailMode = 0
Framerate set to : 24 at NvxVideoEncoderSetParameterNvMMLiteOpen : Block : BlockType = 4 
===== MSENC =====
NvMMLiteBlockCreate : Block : BlockType = 4 
===== MSENC blits (mode: 1) into tiled surfaces =====
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
TVMR: NvMMLiteTVMRDecDoWork: 4017: NVMMLITE_TVMR: EOS detected
TVMR: TVMRBufferProcessing: 3454: Processing of EOS Done
Got EOS from element "pipeline0".
Execution ended after 0:00:17.145813362
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
TVMR: TVMRFrameDelivery: 3675: Closing TVMR Frame Delivery Thread -------------
TVMR: NvMMDecTVMRDestroyParser: 4153: NvAvpClose
TVMR: NvMMLiteTVMRDecBlockClose: 5092: Done 
Setting pipeline to NULL ...
Freeing pipeline ...

tegrastats shows

RAM 486/1892MB (lfb 2x1MB) cpu [19%,7%,10%,8%]@2320 EMC 22%@924 AVP 2%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 488/1892MB (lfb 2x1MB) cpu [13%,9%,13%,9%]@2320 EMC 30%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 489/1892MB (lfb 2x1MB) cpu [17%,11%,12%,9%]@2320 EMC 29%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [16%,9%,8%,9%]@2320 EMC 29%@924 AVP 3%@204 VDE 528 GR3D 0%@852 EDP limit 0
RAM 489/1892MB (lfb 2x1MB) cpu [17%,11%,10%,10%]@2320 EMC 31%@924 AVP 3%@204 VDE 528 GR3D 0%@852 EDP limit 0
RAM 489/1892MB (lfb 2x1MB) cpu [21%,13%,14%,14%]@2320 EMC 29%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [15%,11%,9%,11%]@2320 EMC 28%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [11%,10%,5%,6%]@2320 EMC 25%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 489/1892MB (lfb 2x1MB) cpu [12%,11%,9%,11%]@2320 EMC 26%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [6%,9%,8%,11%]@2320 EMC 26%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [14%,11%,6%,7%]@2320 EMC 27%@924 AVP 3%@204 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [16%,11%,16%,13%]@2320 EMC 28%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 491/1892MB (lfb 2x1MB) cpu [15%,12%,6%,9%]@2320 EMC 29%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 490/1892MB (lfb 2x1MB) cpu [17%,16%,6%,9%]@2320 EMC 28%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 491/1892MB (lfb 2x1MB) cpu [17%,14%,15%,12%]@2320 EMC 27%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 492/1892MB (lfb 2x1MB) cpu [20%,10%,15%,10%]@2320 EMC 28%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0
RAM 492/1892MB (lfb 2x1MB) cpu [18%,12%,11%,38%]@2320 EMC 30%@924 AVP 3%@300 VDE 528 GR3D 0%@852 EDP limit 0

we have already enabled both of four CPU as below:

sunz@tegra-ubuntu:/media/hdisk1/sunz/tmp$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor               
performance
sunz@tegra-ubuntu:/media/hdisk1/sunz/tmp$ cat /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
performance
sunz@tegra-ubuntu:/media/hdisk1/sunz/tmp$ cat /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
performance
sunz@tegra-ubuntu:/media/hdisk1/sunz/tmp$ cat /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
performance
sunz@tegra-ubuntu:/media/hdisk1/sunz/tmp$

are there any additional suggestions?

thanks
-zhi