This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ELF instruction for section and branch.


[This is very off-topic for the gcc lists.  I've kept it cc'ed so that
 people know about the reply, but please respond privately.]

"Gagneet Singh" <gagneet@acmet.com> writes:
> We have come to a conclusion that if we branch to a label local to the
> section in which the branch is invoked and then jump to the desired
> location in the other section it should solve the problem. 
>
> 	.section .text1
> foo:	
> 	b	L1
>
> L1:
> 	j	bar
>
>
> 	.section .text2
> bar:
> 	add	r4, r5, r6
>
>
> Are we correct in assuming this?

Well, this example doesn't make much sense: you could simply have
"foo: j bar".  But yes, you can implement conditional branches to
bar using this sort of scheme.

Richard


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]