# How to correctly determine the \`-march\` flag when working with Intel oneAPI on Intel processors?

**URL:** <https://fortran-lang.discourse.group/t/how-to-correctly-determine-the-march-flag-when-working-with-intel-oneapi-on-intel-processors/2826>\
**Category:** Help\
**Created:** [February 19, 2022, 3:03am UTC](https://fortran-lang.discourse.group/t/how-to-correctly-determine-the-march-flag-when-working-with-intel-oneapi-on-intel-processors/2826 "2022-02-19T03:03:47Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![Hongyi](https://avatars.discourse-cdn.com/v4/letter/h/5fc32e/32.png) [@Hongyi](https://fortran-lang.discourse.group/u/Hongyi)\
**Post date:** [February 19, 2022, 2:46pm UTC](https://fortran-lang.discourse.group/t/how-to-correctly-determine-the-march-flag-when-working-with-intel-oneapi-on-intel-processors/2826/6 "2022-02-19T14:46:07Z")

</div>

> [@msz59](#):
>
> You can find the proper _codename_ in the first line of `inxi -Cxxx` output:
> 
> > arch: Broadwell
> 
> thus, use `-march=broadwell`  
> If not available you can always leave the detection of the proper _family_ to the compiler, using `-march=native`

Wonderful advice. Based on your above comment, I’ve confirmed that both of the following settings solve the problem discussed here:

`FFLAGS += -march=broadwell`

or

`FFLAGS += -march=native`

Regards,  
HZ

---

_[View the full topic](https://fortran-lang.discourse.group/t/how-to-correctly-determine-the-march-flag-when-working-with-intel-oneapi-on-intel-processors/2826)._
