Informational output

I am having some troube in using my Makefile to compile my progam and to give me information on all of the loops that are parallelizable and those that are not.

I am seeking output like:

main:
24, Generating copyout(r[0:n-1])
Generating copyin(a[0:n-1])
Generating compute capability 1.0 binary
Generating compute capability 2.0 binary
26, Loop is parallelizable
Accelerator kernel generated
26, #pragma acc for parallel, vector(256) /* blockIdx.x threadIdx.x */
CC 1.0 : 3 registers; 48 shared, 4 constant, 0 local memory bytes
CC 2.0 : 10 registers; 4 shared, 60 constant, 0 local memory bytes

but what I am gettng is:

ray_sgm2.c:130: warning: ignoring #pragma acc region
ray_sgm2.c:692: warning: ignoring #pragma acc region
ray_sgm2.c:707: warning: ignoring #pragma acc region
ray_sgm2.c:760: warning: ignoring #pragma acc region

Now I understand that I know it can ignore a loop if it is not paraeleizable, but it should at least give me a reason instead of just saying ignoring it. The example is the first section of output vs. the second section show the contrast.

Now please undertand that these output files came from dfferent sets of code. Thus they will be different in their output. However, I just want more info than what I am getting.

I believe the key is the command line option Minfo. But what do I do with it?

My makefile is

CC=gcc
CFLAGS=-c -Wall -O0 -Minfo=ccff -Mprof=lines
LDFLAGS= -lm -lrt
SOURCES= main.c WEGprint.c InitializeScenarioData.c WAFmutex.c P_tra_ray2.c thread.c P_prc_typ2.c set_nod2.c env_nodb.c vlm_atnb.c tra_ray2.c zro_rng2.c lin_lin.c test_vlm_atn3.c prc_typ2.c ray_sgm2.c vlm_atn3.c ray_typ2.c test_ndx_tbl.c str_eig.c zsbl94.c snd_slw2.c ndx_tbl.c btm_dptb.c lwr_vtx2.c rfl_srf2.c rfl_btm2.c zbtms94.c zbtmrf9.c vrt_typ2.c dcm_sgm2.c vrt_tim2.c prc_ray2.c vrt_srf2.c srf_int2.c vrt_btm2.c btm_int2.c vrt_ray2.c gnr_seq.c chn_rfl2.c unfold2.c int_bnd2.c nrm_bnd2.c zblos94.c zbtmr04.c zsigmpr.c zsigmpv.c trn_mtx2.c adv_mtx2.c zelblos.c zbrlael.c WAFmathComplex.c zgsiz2des.c zgam.c zbeta.c WEG.c src_ang2.c prc_brn2.c merge.c IntSrcRays.c

OBJECTS=$(SOURCES:.c=.o)
EXECUTABLE=grab_64

all: $(SOURCES) $(EXECUTABLE)

$(EXECUTABLE): $(OBJECTS)
$(CC) $(LDFLAGS) $(OBJECTS) -o $@

.c.o:
$(CC) $(CFLAGS) $< -o $@

I do not know what i did to get such a lean uninformational output.

Any help appreciated. Thanks in advance.

Newport_j

Hi THX 1138,

The GNU C complier, gcc, doesn’t recognise the PGI Accelerator Model pragmas. Please use PGI’s C compiler, pgcc, instead. You will need to change your flags as well to remove “-Wall” and add “-ta=nvidia”.

  • Mat

Yes, that was clumsy. I will make the changes.

A few questions though. What does, -Wall, mean on a gcc command line. I use it a lot, but I cannnot remember what it means.

Also, what compiler command line flags must be changed for pgcc instead of gcc?

Thank in advance.

THX 1138

I’ll take a stab at answering this. -Wall turns on all warnings for things “most” users find objectionable. -Wextra turns on more warnings for things that are a bit more iffy. (The PGI equivalent, I guess, might be -Minform=inform…but I’m not sure. I think by default PGI uses -Minform=warn (whether you ask for it or not) which might already warn about everything -Wall would.)

And, as Mat said, you’ll want to add ‘-ta=nvidia’ to target the accelerator.

Matt