sparse 32bit test failures

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Luc,

As you may remember, I occasionally build sparse on 32bit Linux. This build
failed recently and I have been trying, without success, to find time to look
into the reasons for the failure. Today I had a _very_ quick look and used
git bisect to at least pin down the commits which introduced the three new
test failures. Unfortunately, I don't have time to look at this further at
the moment, so I thought I should let you know what I have found so far.

The first bisect run netted two new failures:

  $ git bisect good
  6dea652c4ac3aec57ffb1ce7c333184d324971f8 is the first bad commit
  commit 6dea652c4ac3aec57ffb1ce7c333184d324971f8
  Author: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
  Date:   Mon Apr 9 16:49:09 2018 +0200
  
      ssa: activate the new SSA conversion
      
      This activate the new SSA conversion that will be used
      to replace simplify_symbol_usage() which created invalid
      SSA (phi-nodes were placed where the value was needed
      instead of where the paths meet, also and partially related,
      it was possible for a phi-node to have more operands/sources
      than the BB it was in had parents).
      
      Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
  
  :100644 100644 e682b7b2fd094c709c004abdcc621120020ce5c0 e8cb7fc31e4b0648f0748aa160d027966c5b0c22 M	optimize.c
  :040000 040000 ecb4b4e6116b3db1a9d324f0081a14037c7899ad c3f7fd50712a32eb3c48c31988066f21aa5278e1 M	validation
  $ 
  
  $ make check
  ...
    TEST    init-local (mem2reg/init-local.c)
  error: test 'mem2reg/init-local.c' failed
  error: 	Pattern 'load\.' unexpectedly present
  ...
    TEST    cse-size (optim/cse-size.c)
  error: test 'optim/cse-size.c' failed
  error: 	Pattern 'phi\.' expected 2 times but got 1 times
  ...
    TEST    warn-unknown-attribute-yes (Wunknown-attribute-yes.c)
  KO: out of 447 tests, 400 passed, 47 failed
  	45 of them are known to fail
  	43 tests were disabled
  Makefile:228: recipe for target 'check' failed
  make: *** [check] Error 1
  $ 

The second bisect run netted the final new failure:
  
  $ git bisect good
  d96da358cfa0432f067a4e66940765883b80ee62 is the first bad commit
  commit d96da358cfa0432f067a4e66940765883b80ee62
  Author: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
  Date:   Fri Jun 29 00:35:44 2018 +0200
  
      stricter warning for explicit cast to ulong
      
      sparse issues a warning when user pointers are casted to integer
      types except to unsigned longs which are explicitly allowed.
      However it may happen that we would like to also be warned
      on casts to unsigned long.
      
      Fix this by adding a new warning flag: -Wcast-from-as (to mirrors
      -Wcast-to-as) which extends -Waddress-space to all casts that
      remove an address space attribute (without using __force).
      
      References: https://lore.kernel.org/lkml/20180628102741.vk6vphfinlj3lvhv@xxxxxxxxxxxxxxxxxxxxxxxxxxxx/
      Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
  
  :100644 100644 7ab7db816fa510355fc1a78338e8ee5a2ef820b0 6d5d4793f95ba209b5811f389fc33532615bcf93 M	evaluate.c
  :100644 100644 48c6dc9837f05615edee2ec5b59877d2e4a4ead5 652780aef21ae9a14d0f34c540578c54261cdbc8 M	lib.c
  :100644 100644 8b44520404a97d474f7e74a73fbdc293e5a3f2f5 cd1af9c4a3b735ff1281429c13dcd84a4a0c9109 M	lib.h
  :100644 100644 8a14a6be38e2ca941c68f7090e567b66a30c85bf 3e1352352e43f91203094e9e27955c5fe5fbda63 M	sparse.1
  :040000 040000 c49cea4496251ba125aea025142ca2320bbd1729 3267792a3897d8c3adad02696e964d0ef793dd25 M	validation
  $ 
  
  $ make check
  ...
    TEST    init-local (mem2reg/init-local.c)
  error: test 'mem2reg/init-local.c' failed
  error: 	Pattern 'load\.' unexpectedly present
  ...
    TEST    cse-size (optim/cse-size.c)
  error: test 'optim/cse-size.c' failed
  error: 	Pattern 'phi\.' expected 2 times but got 1 times
  ...
    TEST    Waddress-space-strict (Waddress-space-strict.c)
  error: actual error text does not match expected error text.
  error: see Waddress-space-strict.c.error.* for further investigation.
  --- Waddress-space-strict.c.error.expected	2018-09-08 21:14:27.297819515 +0100
  +++ Waddress-space-strict.c.error.got	2018-09-08 21:14:27.289819441 +0100
  @@ -8,7 +8,7 @@
   Waddress-space-strict.c:30:10: warning: cast removes address space of expression
   Waddress-space-strict.c:31:10: warning: cast removes address space of expression
   Waddress-space-strict.c:32:10: warning: cast removes address space of expression
  -Waddress-space-strict.c:9:18: warning: non size-preserving integer to pointer cast
  -Waddress-space-strict.c:10:25: warning: non size-preserving integer to pointer cast
  -Waddress-space-strict.c:21:15: warning: non size-preserving pointer to integer cast
  -Waddress-space-strict.c:28:15: warning: non size-preserving pointer to integer cast
  +Waddress-space-strict.c:15:18: warning: non size-preserving integer to pointer cast
  +Waddress-space-strict.c:16:25: warning: non size-preserving integer to pointer cast
  +Waddress-space-strict.c:23:17: warning: non size-preserving pointer to integer cast
  +Waddress-space-strict.c:30:17: warning: non size-preserving pointer to integer cast
  ...
    TEST    warn-unknown-attribute-yes (Wunknown-attribute-yes.c)
  KO: out of 539 tests, 482 passed, 57 failed
  	54 of them are known to fail
  	43 tests were disabled
  Makefile:228: recipe for target 'check' failed
  make: *** [check] Error 1
  $ 
  
Just looking at the output of the third failure above, it seems clear that
this is caused by the test expectation that a pointer is 64-bit. I suspect,
but haven't tried, adding '-m64' to the command line would fix that test.
(But that begs the question about checking 32-bit pointers).

I can't tell anything from the output of the first two failures! ;-)

I have to go now.

ATB,
Ramsay Jones



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux