From: Wolfgang Denk Date: Wed, 12 Feb 2014 16:51:09 +0100 Subject: [U-Boot] [PATCH v2] arm: Switch to -mno-unaligned-access when supported by the compiler In-Reply-To: <20140212142536.GA15819@bill-the-cat> References: <20140210132139.GT7049@bill-the-cat> <20140210155751.23849fcb@lilith> <20140210171224.477e2906@lilith> <20140210162403.GV7049@bill-the-cat> <20140210182646.2de92810@lilith> <20140210212630.GB7049@bill-the-cat> <20140210221723.B3DFB380603@gemini.denx.de> <20140210222819.GE7049@bill-the-cat> <20140211094450.361b3218@lilith> <20140212142536.GA15819@bill-the-cat> Message-ID: <20140212155109.EAE60380601@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Tom, In message <20140212142536.GA15819@bill-the-cat> you wrote: > > No. The solution is to tell the compiler which optimizations it can, > and cannot use. If we stop telling it that native unaligned accesses > work it won't decide to make use of those optimizations. Can we do this in such a way that we can be absolutely sure that the compiler will never break up larger (say 32 bit) accesses into smaller (say, 2 x 16 bit or 4 x 8 bit or similar) accesses? Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de A wise person makes his own decisions, a weak one obeys public opinion. -- Chinese proverb