* [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>' width not an integer constant
[not found] <CAO_Arvrp4GwhVr_c170hD3eQ8F77WSmsY4wsCOpg3Xdg23jjKw@mail.gmail.com>
@ 2014-02-03 15:50 ` Mathieu Desnoyers
2014-02-04 10:13 ` kumar s
0 siblings, 1 reply; 4+ messages in thread
From: Mathieu Desnoyers @ 2014-02-03 15:50 UTC (permalink / raw)
----- Original Message -----
> From: "kumar s" <skumar.m226@gmail.com>
> To: lttng-dev at lists.lttng.org
> Sent: Tuesday, December 3, 2013 3:20:02 AM
> Subject: [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>'
> width not an integer constant
> Hello,
> When trying to build lttng modules i am getting this error. Cross compiler
> for mips and Arch = mips is used in makefile.
> Linux kernel version 2.6.32.27
> make -C
> /home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux
> M=/home/shkumar/lttng-tools/lttngmod/lttng-modules modules ARCH=mips
> CROSS_COMPILE=mips64-octeon-linux-gnu-
> make[1]: Entering directory
> `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
> CC [M]
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o
> In file included from
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/config.h:1,
> from /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer-core.h:35,
> from /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer.h:39,
> from
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.c:24:
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:
> In function 'lib_ring_buffer_align':
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:266:
> error: bit-field '<anonymous>' width not an integer constant
> make[2]: ***
> [/home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o]
> Error 1
> make[1]: *** [_module_/home/shkumar/lttng-tools/lttngmod/lttng-modules] Error
> 2
> make[1]: Leaving directory
> `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
> make: *** [default] Error 2
> How do i fix this?
This is caused by the use of offset_align(), passing incorrect parameters, detected by the compiler:
see lttng-modules
lib/align.h:
#define offset_align(align_drift, alignment) \
({ \
BUILD_RUNTIME_BUG_ON((alignment) == 0 \
|| ((alignment) & ((alignment) - 1))); \
(((alignment) - (align_drift)) & ((alignment) - 1)); \
})
See also lttng-modules
lib/bug.h
So there are two things that are possible: either the compiler you use does not perform the
optimisations that are expected, and therefore triggers the BUILD_BUG_ON() without needing to,
or there really is an incorrect value passed to offset_align().
Make sure lttng-modules, your compiler toolchain, and your kernel are up to date.
Thanks,
Mathieu
> Skumar.
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140203/6115cb42/attachment.html>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>' width not an integer constant
2014-02-03 15:50 ` [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>' width not an integer constant Mathieu Desnoyers
@ 2014-02-04 10:13 ` kumar s
2014-02-04 14:52 ` Mathieu Desnoyers
0 siblings, 1 reply; 4+ messages in thread
From: kumar s @ 2014-02-04 10:13 UTC (permalink / raw)
Hi,
The lttng module i use is the latest version, compiler toolchain cannot be
upgraded since it is provided by Cavium, kernel version is 2.6.32.27.
Is there any change i need to do on lttng modules to build it?
Thank you
SKumar
On Mon, Feb 3, 2014 at 9:20 PM, Mathieu Desnoyers <
mathieu.desnoyers at efficios.com> wrote:
> ------------------------------
>
> *From: *"kumar s" <skumar.m226@gmail.com>
> *To: *lttng-dev at lists.lttng.org
> *Sent: *Tuesday, December 3, 2013 3:20:02 AM
> *Subject: *[lttng-dev] lib_ring_buffer_align error bit-field
> '<anonymous>' width not an integer constant
>
>
> Hello,
>
> When trying to build lttng modules i am getting this error. Cross compiler
> for mips and Arch = mips is used in makefile.
>
> Linux kernel version 2.6.32.27
>
>
> make -C
> /home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux
> M=/home/shkumar/lttng-tools/lttngmod/lttng-modules modules ARCH=mips
> CROSS_COMPILE=mips64-octeon-linux-gnu-
> make[1]: Entering directory
> `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
> CC [M]
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o
> In file included from
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/config.h:1,
> from
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer-core.h:35,
> from
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer.h:39,
> from
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.c:24:
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:
> In function 'lib_ring_buffer_align':
> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:266:
> error: bit-field '<anonymous>' width not an integer constant
> make[2]: ***
> [/home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o]
> Error 1
> make[1]: *** [_module_/home/shkumar/lttng-tools/lttngmod/lttng-modules]
> Error 2
> make[1]: Leaving directory
> `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
> make: *** [default] Error 2
>
> How do i fix this?
>
>
> This is caused by the use of offset_align(), passing incorrect parameters,
> detected by the compiler:
>
> see lttng-modules
>
> lib/align.h:
>
> #define offset_align(align_drift,
> alignment) \
>
> ({ \
> BUILD_RUNTIME_BUG_ON((alignment) ==
> 0 \
> || ((alignment) & ((alignment) -
> 1))); \
> (((alignment) - (align_drift)) & ((alignment) -
> 1)); \
> })
>
> See also lttng-modules
> lib/bug.h
>
> So there are two things that are possible: either the compiler you use
> does not perform the
> optimisations that are expected, and therefore triggers the BUILD_BUG_ON()
> without needing to,
> or there really is an incorrect value passed to offset_align().
>
> Make sure lttng-modules, your compiler toolchain, and your kernel are up
> to date.
>
> Thanks,
>
> Mathieu
>
>
> Skumar.
>
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>
>
>
>
> --
> Mathieu Desnoyers
> EfficiOS Inc.
> http://www.efficios.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140204/79f94b54/attachment-0001.html>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>' width not an integer constant
2014-02-04 10:13 ` kumar s
@ 2014-02-04 14:52 ` Mathieu Desnoyers
[not found] ` <CAO_ArvrPPJZ4H_cLx4uFd=wd7XPuq=PDEU_RqU2=3k4Bjx5Czw@mail.gmail.com>
0 siblings, 1 reply; 4+ messages in thread
From: Mathieu Desnoyers @ 2014-02-04 14:52 UTC (permalink / raw)
You might want to request help from Cavium, since they are the one supporting
their toolchain.
It really seems to be a Cavium-specific issue.
Thanks,
Mathieu
----- Original Message -----
> From: "kumar s" <skumar.m226@gmail.com>
> To: "Mathieu Desnoyers" <mathieu.desnoyers at efficios.com>
> Cc: lttng-dev at lists.lttng.org
> Sent: Tuesday, February 4, 2014 5:13:44 AM
> Subject: Re: [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>'
> width not an integer constant
> Hi,
> The lttng module i use is the latest version, compiler toolchain cannot be
> upgraded since it is provided by Cavium, kernel version is 2.6.32.27.
> Is there any change i need to do on lttng modules to build it?
> Thank you
> SKumar
> On Mon, Feb 3, 2014 at 9:20 PM, Mathieu Desnoyers <
> mathieu.desnoyers at efficios.com > wrote:
> > > From: "kumar s" < skumar.m226@gmail.com >
> >
>
> > > To: lttng-dev at lists.lttng.org
> >
>
> > > Sent: Tuesday, December 3, 2013 3:20:02 AM
> >
>
> > > Subject: [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>'
> > > width not an integer constant
> >
>
> > > Hello,
> >
>
> > > When trying to build lttng modules i am getting this error. Cross
> > > compiler
> > > for mips and Arch = mips is used in makefile.
> >
>
> > > Linux kernel version 2.6.32.27
> >
>
> > > make -C
> > > /home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux
> > > M=/home/shkumar/lttng-tools/lttngmod/lttng-modules modules ARCH=mips
> > > CROSS_COMPILE=mips64-octeon-linux-gnu-
> >
>
> > > make[1]: Entering directory
> > > `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
> >
>
> > > CC [M]
> > > /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o
> >
>
> > > In file included from
> > > /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/config.h:1,
> >
>
> > > from
> > > /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer-core.h:35,
> >
>
> > > from /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer.h:39,
> >
>
> > > from
> > > /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.c:24:
> >
>
> > > /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:
> > > In function 'lib_ring_buffer_align':
> >
>
> > > /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:266:
> > > error: bit-field '<anonymous>' width not an integer constant
> >
>
> > > make[2]: ***
> > > [/home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o]
> > > Error 1
> >
>
> > > make[1]: *** [_module_/home/shkumar/lttng-tools/lttngmod/lttng-modules]
> > > Error
> > > 2
> >
>
> > > make[1]: Leaving directory
> > > `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
> >
>
> > > make: *** [default] Error 2
> >
>
> > > How do i fix this?
> >
>
> > This is caused by the use of offset_align(), passing incorrect parameters,
> > detected by the compiler:
>
> > see lttng-modules
>
> > lib/align.h:
>
> > #define offset_align(align_drift, alignment) \
>
> > ({ \
>
> > BUILD_RUNTIME_BUG_ON((alignment) == 0 \
>
> > || ((alignment) & ((alignment) - 1))); \
>
> > (((alignment) - (align_drift)) & ((alignment) - 1)); \
>
> > })
>
> > See also lttng-modules
>
> > lib/bug.h
>
> > So there are two things that are possible: either the compiler you use does
> > not perform the
>
> > optimisations that are expected, and therefore triggers the BUILD_BUG_ON()
> > without needing to,
>
> > or there really is an incorrect value passed to offset_align().
>
> > Make sure lttng-modules, your compiler toolchain, and your kernel are up to
> > date.
>
> > Thanks,
>
> > Mathieu
>
> > > Skumar.
> >
>
> > > _______________________________________________
> >
>
> > > lttng-dev mailing list
> >
>
> > > lttng-dev at lists.lttng.org
> >
>
> > > http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
> >
>
> > --
>
> > Mathieu Desnoyers
>
> > EfficiOS Inc.
>
> > http://www.efficios.com
>
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140204/54459595/attachment.html>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [lttng-dev] Fwd: lib_ring_buffer_align error bit-field '<anonymous>' width not an integer constant
[not found] ` <CAO_ArvrPPJZ4H_cLx4uFd=wd7XPuq=PDEU_RqU2=3k4Bjx5Czw@mail.gmail.com>
@ 2014-02-07 4:38 ` kumar s
0 siblings, 0 replies; 4+ messages in thread
From: kumar s @ 2014-02-07 4:38 UTC (permalink / raw)
---------- Forwarded message ----------
From: kumar s <skumar.m226@gmail.com>
Date: Fri, Feb 7, 2014 at 10:08 AM
Subject: Re: [lttng-dev] lib_ring_buffer_align error bit-field
'<anonymous>' width not an integer constant
To: Mathieu Desnoyers <mathieu.desnoyers at efficios.com>
Hi,
In bug.h, i removed the underlined lines and left only BUG_ON(condition).
The modules got compiled without any errors, however are there any issues
on removing the underlined lines.
*/
#define BUILD_RUNTIME_BUG_ON(condition) \
do { \
*- *
* if (__builtin_constant_p(condition)) \
- BUILD_BUG_ON(condition);
\- else * \
BUG_ON(condition); \
} while (0)
thank you
Skumar
On Tue, Feb 4, 2014 at 8:22 PM, Mathieu Desnoyers <
mathieu.desnoyers at efficios.com> wrote:
> You might want to request help from Cavium, since they are the one
> supporting
> their toolchain.
>
> It really seems to be a Cavium-specific issue.
>
> Thanks,
>
> Mathieu
>
>
> ------------------------------
>
> *From: *"kumar s" <skumar.m226@gmail.com>
> *To: *"Mathieu Desnoyers" <mathieu.desnoyers at efficios.com>
> *Cc: *lttng-dev at lists.lttng.org
> *Sent: *Tuesday, February 4, 2014 5:13:44 AM
> *Subject: *Re: [lttng-dev] lib_ring_buffer_align error bit-field
> '<anonymous>' width not an integer constant
>
>
> Hi,
>
> The lttng module i use is the latest version, compiler toolchain cannot be
> upgraded since it is provided by Cavium, kernel version is 2.6.32.27.
>
> Is there any change i need to do on lttng modules to build it?
>
> Thank you
> SKumar
>
>
> On Mon, Feb 3, 2014 at 9:20 PM, Mathieu Desnoyers <
> mathieu.desnoyers at efficios.com> wrote:
>
>> ------------------------------
>>
>> *From: *"kumar s" <skumar.m226@gmail.com>
>> *To: *lttng-dev at lists.lttng.org
>> *Sent: *Tuesday, December 3, 2013 3:20:02 AM
>> *Subject: *[lttng-dev] lib_ring_buffer_align error bit-field
>> '<anonymous>' width not an integer constant
>>
>>
>> Hello,
>>
>> When trying to build lttng modules i am getting this error. Cross
>> compiler for mips and Arch = mips is used in makefile.
>>
>> Linux kernel version 2.6.32.27
>>
>>
>> make -C
>> /home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux
>> M=/home/shkumar/lttng-tools/lttngmod/lttng-modules modules ARCH=mips
>> CROSS_COMPILE=mips64-octeon-linux-gnu-
>> make[1]: Entering directory
>> `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
>> CC [M]
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o
>> In file included from
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/config.h:1,
>> from
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer-core.h:35,
>> from
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-tracer.h:39,
>> from
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.c:24:
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:
>> In function 'lib_ring_buffer_align':
>> /home/shkumar/lttng-tools/lttngmod/lttng-modules/wrapper/ringbuffer/../../lib/ringbuffer/config.h:266:
>> error: bit-field '<anonymous>' width not an integer constant
>> make[2]: ***
>> [/home/shkumar/lttng-tools/lttngmod/lttng-modules/lttng-ring-buffer-client-discard.o]
>> Error 1
>> make[1]: *** [_module_/home/shkumar/lttng-tools/lttngmod/lttng-modules]
>> Error 2
>> make[1]: Leaving directory
>> `/home/shkumar/Development_Merge/NewOCT/OCTEON_SDK/octeon_sdk/OCTEON-SDK/linux/kernel_2.6/linux'
>> make: *** [default] Error 2
>>
>> How do i fix this?
>>
>>
>> This is caused by the use of offset_align(), passing incorrect
>> parameters, detected by the compiler:
>>
>> see lttng-modules
>>
>> lib/align.h:
>>
>> #define offset_align(align_drift,
>> alignment) \
>>
>> ({ \
>> BUILD_RUNTIME_BUG_ON((alignment) ==
>> 0 \
>> || ((alignment) & ((alignment) -
>> 1))); \
>> (((alignment) - (align_drift)) & ((alignment) -
>> 1)); \
>> })
>>
>> See also lttng-modules
>> lib/bug.h
>>
>> So there are two things that are possible: either the compiler you use
>> does not perform the
>> optimisations that are expected, and therefore triggers the
>> BUILD_BUG_ON() without needing to,
>> or there really is an incorrect value passed to offset_align().
>>
>> Make sure lttng-modules, your compiler toolchain, and your kernel are up
>> to date.
>>
>> Thanks,
>>
>> Mathieu
>>
>>
>> Skumar.
>>
>> _______________________________________________
>> lttng-dev mailing list
>> lttng-dev at lists.lttng.org
>> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>>
>>
>>
>>
>> --
>> Mathieu Desnoyers
>> EfficiOS Inc.
>> http://www.efficios.com
>>
>
>
>
>
> --
> Mathieu Desnoyers
> EfficiOS Inc.
> http://www.efficios.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140207/834420b1/attachment-0001.html>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-02-07 4:38 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <CAO_Arvrp4GwhVr_c170hD3eQ8F77WSmsY4wsCOpg3Xdg23jjKw@mail.gmail.com>
2014-02-03 15:50 ` [lttng-dev] lib_ring_buffer_align error bit-field '<anonymous>' width not an integer constant Mathieu Desnoyers
2014-02-04 10:13 ` kumar s
2014-02-04 14:52 ` Mathieu Desnoyers
[not found] ` <CAO_ArvrPPJZ4H_cLx4uFd=wd7XPuq=PDEU_RqU2=3k4Bjx5Czw@mail.gmail.com>
2014-02-07 4:38 ` [lttng-dev] Fwd: " kumar s
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox