<br><br>On Wednesday, 2 March 2022, FMDF <<a href="mailto:fmdefrancesco@gmail.com">fmdefrancesco@gmail.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 2 Mar 2022, 17:57 Guddla Rupesh, <<a href="mailto:rupeshforu3@gmail.com" target="_blank">rupeshforu3@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><p>I have seen the config from /proc/config.gz and found that processor family as generic x86 64.</p>
<p>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.,.</p></div></blockquote></div></div><div dir="auto">Therefore, in .config, you should enable x86-64. That's it. Simple.</div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">
<p>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.</p></div></blockquote></div></div><div dir="auto">There are no Cometlake or Skylake options for kernel compilation. Your recent CPU is already supported and the whole ISA is available. Compilers know your system and they know which instructions are better suited for your applications and kernel code. </div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">
<p>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.</p></div></blockquote></div></div><div dir="auto">Why have you disabled secure boot mode? If performance concerns you, don't worry about it: there is no loss of performance with secure boot.</div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">
<p>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.</p></div></blockquote></div></div><div dir="auto">No, you're wrong :)</div><div dir="auto"><br></div><div dir="auto">Just select the highest available processor family (I can't recall now if it is "core2" or "generic x86_64", it's the last of the list in the "processor family" section if you use "make menuconfig") and the entire instruction set of Intel x86-64 will be enabled and available. </div><div dir="auto"><br></div><div dir="auto">There is neither a "CONFIG_GENERATION_11" nor similar options.</div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">
<p>I have exported the modules running on system and disable others by running the command</p>
<p>make localmodconfig</p></div></blockquote></div></div><div dir="auto">Beware that using "localmodconfig" disables the build of lots of modules you may need in the future. It relies on the current system configuration. When you'll add new devices you'll have to enable their drivers and recompile the modules.</div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">
<p>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.".</p>
<p>If I can compile kernel source code then my Linux system will run at extreme speeds never before.</p></div></blockquote></div></div><div dir="auto">You might tune the optimization flags of (e.g., GCC's "-On", for n=0,1,2, and others) but I strongly advise you to not do this because (1) it is clear that you don't understand how the code is compiled and (2) you probably won't get the results you think you should get.</div><div dir="auto"><br></div><div dir="auto">Regards,</div><div dir="auto"><br></div><div dir="auto">Fabio M. De Francesco</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
______________________________<wbr>_________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org" rel="noreferrer" target="_blank">Kernelnewbies@kernelnewbies.<wbr>org</a><br>
<a href="https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" rel="noreferrer noreferrer" target="_blank">https://lists.kernelnewbies.<wbr>org/mailman/listinfo/<wbr>kernelnewbies</a><br>
</blockquote></div></div></div></blockquote><div>No kernel should be compiled with compiler optimization, because the compiler might remove CPU instructions and code that might look "unnecessary" but are actually required.</div>