<div dir="auto"><div dir="auto">Pentium MMX was launched about 30 years ago and at that time video processing was new and there was no proper hardware just to play any video file I mean if you play any video file video playback stops sometimes and resume after some time.</div><div dir="auto"><br></div><div dir="auto">At present there is lot of development in video hardware and at the same time new technologies in both hardware and software has been evolved. Coming into hardware CPUs with integrated graphics came and coming into software many video and audio codecs have been developed like h265, vpx, av1, aac, opus etc.,.Of these aac and opus are audio codecs which produces lowest disk size at reasonable quality and h265, av1 are video codecs which provides lowest disk size at reasonable quality.</div><div dir="auto"><br></div><div dir="auto">Most of the time I download videos from youtube and other sources which are of large size. When you record a video in android smartphone it takes around 600 mb for 3 minutes 50 seconds and it uses h265 codec. It is difficult to store such files in my android smartphone.</div><div dir="auto"><br></div><div dir="auto">Mostly I use Linux and ffmpeg tool to compress these video files. Of h265 and av1 aom encoders. av1 aom encoder provide lowest disk size at lowest video bitrate. H265 encoding and decoding are supported in all hardware including pc and smartphone but unfortunately av1 files are not supported in none but definitely I think that it will become defacto standard in future.</div><div dir="auto"><br></div><div dir="auto">If h265 encoding takes 1 minute then aom av1 encoding takes about 10 minutes. If video acceleration is present the encoding takes about 7 minutes. Video acceleration come into action only if GPU is detected properly and the necessary drivers are installed. If the system can detect opecl version of GPU then av1 encoding takes about 5 minutes through ffmpeg.</div><div dir="auto"><br></div><div dir="auto">As MMX was trending about 30 years ago I think that latest processors have vector instructions for video transcoding or encoding like avx2 or avx 512, simd etc.,. These new instructions are not present in 15 years back processors.</div><div dir="auto"><br></div><div dir="auto">As 64 bit processor came into action around 20 years back nowadays processors are 10 times are greater in performance than old.</div><div dir="auto"><br></div><div dir="auto">I think that all the kernels shipped by distros are not considering latest processors instruction set. I think that even windows is doing the same. </div><div dir="auto"><br></div><div dir="auto">If opencl is detected properly any application can have improvement in performance about 10 percent.</div><div dir="auto"><br></div><div dir="auto">I can't find any option to set opencl in the Linux kernel config file or in any of the kernel source files.</div><div dir="auto"><br></div><div dir="auto">Atleast I am lucky to select option core 2 in the main .config file of kernel.</div><div dir="auto"><br></div><div dir="auto">Finally my request is there any way to export instruct set of my cpu to the kernel configuration and so after compilation my video encoding takes less time than previous.</div><div dir="auto"><br></div><div dir="auto">If it's a difficult task leave it and if it's possible try to suggest how to do so.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, 3 Mar 2022, 2:15 am Rogério Valentim Feitoza da Silva, <<a href="mailto:rogerio.silva3920@gmail.com">rogerio.silva3920@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Wednesday, 2 March 2022 at 13:56, Guddla Rupesh<br>
<<a href="mailto:rupeshforu3@gmail.com" target="_blank" rel="noreferrer">rupeshforu3@gmail.com</a>> wrote:<br>
><br>
> I have seen the config from /proc/config.gz and found that processor family as generic x86 64.<br>
><br>
> Actually my system consists of i3 10th gen comet lake 10100 which has integrated graphics and pci express 4.0 and also lots of new instructions like avx2, sse4 etc.,.<br>
><br>
> The main reason of compiling source code of kernel is it detects all my hardware and provide support for opencl, video acceleration etc.,. But I can't find any option to select my processor especially comet lake or atleast skylake and instead there is an option called core2 in the section processor family.<br>
><br>
> Finally I have disabled secure boot mode in bios and compiled source code successfully and now I am able to boot into the latest build kernel but there is no difference in performance between old and new kernels.<br>
><br>
> I think that normal kernel shipped by the distro is generic and it doesn't have support for latest instructions like avx2, sse4 etc.,. To get support we must compile kernel with lots of tuning.<br>
><br>
> I have exported the modules running on system and disable others by running the command<br>
><br>
> make localmodconfig<br>
><br>
> What I want is " is there any way to export my cpu instruction set to kernel .config file and compile kernel and install the modules.".<br>
><br>
> If I can compile kernel source code then my Linux system will run at extreme speeds never before.<br>
><br>
><br>
> On Tue, 1 Mar 2022, 11:28 pm Rogério Valentim Feitoza da Silva, <<a href="mailto:rogerio.silva3920@gmail.com" target="_blank" rel="noreferrer">rogerio.silva3920@gmail.com</a>> wrote:<br>
>><br>
>> On Tuesday, 1 March 2022 at 00:08, Guddla Rupesh <<a href="mailto:rupeshforu3@gmail.com" target="_blank" rel="noreferrer">rupeshforu3@gmail.com</a>> wrote:<br>
>> ><br>
>> > Hi I am Rupesh from India and I have pc i3 processor and h510 motherboard It has uefi. I have installed open suse tumblewood and all the packages have been updated. As the default kernel provided by open suse tumblewood is not working properly I want to compile source code of new kernel which is obtained from <a href="http://kernel.org" rel="noreferrer noreferrer" target="_blank">kernel.org</a> and the kernel source code present in /usr/src/linux*** but I can't.<br>
>> ><br>
>> > As the pc is uefi based I am getting lot of errors related to signing. I have installed all latest packages related to gcc, make, ctags, cscope, open ssh, open SSL, auto make, auto conf, cmake etc.,.<br>
>> ><br>
>> > I have created the config file from the existing configuration of system using the following command<br>
>> ><br>
>> > make localmodconfig<br>
>> ><br>
>> > I have succeeded in compiling source code of new kernel using make command but when I execute the command<br>
>> ><br>
>> > make install<br>
>> ><br>
>> > I am getting error as<br>
>> ><br>
>> > " certificate must have code signing extended key usage defined for secure boot ".<br>
>> ><br>
>> > After some time vmlinux, initrd files are created but when I try to boot the newly compiled kernel from grub I am getting errors as<br>
>> ><br>
>> > "bad shim signature"<br>
>> > "you need to load the kernel first"<br>
>> ><br>
>> > I have tried a number of ways to compile successfully such as disabling secure boot in yast boot loader, selecting load all modules by verifying signature etc.,.<br>
>> ><br>
>> > Currently my .config file consists of the following lines containing the word sig<br>
>> ><br>
>> > [CODE]<br>
>> > CONFIG_SIGNALFD=y<br>
>> > CONFIG_KEXEC_SIG=y<br>
>> > CONFIG_KEXEC_SIG_FORCE=y<br>
>> > CONFIG_KEXEC_BZIMAGE_VERIFY_SIG=y<br>
>> > # CONFIG_STRICT_SIGALTSTACK_SIZE is not set<br>
>> > CONFIG_ACPI_TINY_POWER_BUTTON_SIGNAL=38<br>
>> > CONFIG_OLD_SIGSUSPEND3=y<br>
>> > CONFIG_COMPAT_OLD_SIGACTION=y<br>
>> > CONFIG_DYNAMIC_SIGFRAME=y<br>
>> > CONFIG_MODULE_SIG_FORMAT=y<br>
>> > CONFIG_MODULE_SIG=y<br>
>> > CONFIG_MODULE_SIG_FORCE=y<br>
>> > CONFIG_MODULE_SIG_ALL=y<br>
>> > # CONFIG_MODULE_SIG_SHA1 is not set<br>
>> > # CONFIG_MODULE_SIG_SHA224 is not set<br>
>> > CONFIG_MODULE_SIG_SHA256=y<br>
>> > # CONFIG_MODULE_SIG_SHA384 is not set<br>
>> > # CONFIG_MODULE_SIG_SHA512 is not set<br>
>> > CONFIG_MODULE_SIG_HASH="sha256"<br>
>> > CONFIG_TCP_MD5SIG=y<br>
>> > CONFIG_CFG80211_REQUIRE_SIGNED_REGDB=y<br>
>> > # DesignWare PCI Core Support<br>
>> > # end of DesignWare PCI Core Support<br>
>> > CONFIG_I2C_DESIGNWARE_CORE=y<br>
>> > # CONFIG_I2C_DESIGNWARE_SLAVE is not set<br>
>> > CONFIG_I2C_DESIGNWARE_PLATFORM=y<br>
>> > CONFIG_I2C_DESIGNWARE_BAYTRAIL=y<br>
>> > # CONFIG_I2C_DESIGNWARE_PCI is not set<br>
>> > # CONFIG_SPI_DESIGNWARE is not set<br>
>> > # CONFIG_SND_HDA_CODEC_SIGMATEL is not set<br>
>> > # CONFIG_USB_ISIGHTFW is not set<br>
>> > CONFIG_FS_VERITY_BUILTIN_SIGNATURES=y<br>
>> > CONFIG_INTEGRITY_SIGNATURE=y<br>
>> > # CONFIG_IMA_SIG_TEMPLATE is not set<br>
>> > CONFIG_IMA_APPRAISE_MODSIG=y<br>
>> > CONFIG_IMA_KEYRINGS_PERMIT_SIGNED_BY_BUILTIN_OR_SECONDARY=y<br>
>> > CONFIG_SIGNED_PE_FILE_VERIFICATION=y<br>
>> > # Certificates for signature checking<br>
>> > CONFIG_MODULE_SIG_KEY="certs/signing_key.pem"<br>
>> > CONFIG_MODULE_SIG_KEY_TYPE_RSA=y<br>
>> > # CONFIG_MODULE_SIG_KEY_TYPE_ECDSA is not set<br>
>> > # end of Certificates for signature checking<br>
>> > CONFIG_CHECK_SIGNATURE=y<br>
>> > CONFIG_SIGNATURE=y<br>
>> > [/CODE]<br>
>> ><br>
>> ><br>
>> > Kindly try to suggest how to compile the source code of kernel for uefi system with automatic key singing and how to boot the compiled kernel from grub2.<br>
>> ><br>
>> ><br>
>> > Regards,<br>
>> > Rupesh.<br>
>> > _______________________________________________<br>
>> > Kernelnewbies mailing list<br>
>> > <a href="mailto:Kernelnewbies@kernelnewbies.org" target="_blank" rel="noreferrer">Kernelnewbies@kernelnewbies.org</a><br>
>> > <a href="https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" rel="noreferrer noreferrer" target="_blank">https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
>> The "bad shim signature" error is probably from GRUB's "kernel"<br>
>> command. That might mean the "kernel" command has failed to load the<br>
>> kernel, and therefore the "boot" command failed because there is no<br>
>> kernel to transfer control to.<br>
>><br>
>> -Rogério Valentim<br>
><br>
> _______________________________________________<br>
> Kernelnewbies mailing list<br>
> <a href="mailto:Kernelnewbies@kernelnewbies.org" target="_blank" rel="noreferrer">Kernelnewbies@kernelnewbies.org</a><br>
> <a href="https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" rel="noreferrer noreferrer" target="_blank">https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
If your system is working well, then you don't need to compile a new<br>
Linux kernel. The Linux kernel rarely or never does floating-point<br>
calculations (which is what AVX is used for) and it also doesn't use<br>
SSE for string processing (which is what SSE is used for). I have<br>
looked at the implementation of strcmp() and strcpy() that the Linux<br>
kernel uses, and it doesn't use SSE. Therefore, AVX/SSE won't make a<br>
difference in Linux kernel performance.<br>
<br>
However, user-space applications that frequently process strings<br>
and/or floating-point calculations use the system's C library, which<br>
in most Linux distros is the GNU C library, which optimizes the<br>
strcmp(), strcpy() and other string-processing functions using SSE and<br>
math functions using AVX. But the Linux kernel configuration won't<br>
affect AVX/SSE in userspace.<br>
<br>
Basically, if your system is working well, you don't need to compile<br>
the Linux kernel to use new x86 instruction sets like SSE4 or AVX2.<br>
<br>
-Rogério Valentim<br>
</blockquote></div>