- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Consider the following fortran 2008 program. program foo integer(kind=8) i,j i = z'1111111111111111' j = z'4444444444444444' do n=0,64 print "(i2,': ',z16,2x,z16)",n,dshiftl(i,j,n),dshiftr(i,j,n) end do end program foo
When compiled with Intel Fortran Compiler 14.0.3.174 build 20140422 or 15.0.2.164 build 20150121, it produces the incorrect output for n=0 and n=64,
0: 5555555555555555 5555555555555555 ... 64: 5555555555555555 5555555555555555
It should produce
0: 1111111111111111 4444444444444444 ... 64: 4444444444444444 1111111111111111
This was run on a RHEL 6.6 computer with a haswell processor.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for the report. I'm also seeing the same with 16.0. We will investigate this further.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I reported this issue to the Fortran run-time developer (see internal tracking id below) and will keep this thread updated with the status of a fix as I learn it. Thank you for the convenient reproducer.
(Internal tracking id: DPD200574010)
(Resolution Update on 12/30/2016): This defect is fixed in the Intel® Parallel Studio XE 2017 Initial Release (ifort Version 17.0.0.098 Build 20160721 - PSXE 2017.0.035 / CnL 2017.0.098 - Linux)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Shouldn't the correct DSHIFTL for count of 64 produce
444444440000000
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Pardon the delayed notification. I confirmed this defect was fixed in the Intel® Parallel Studio XE 2017 initial release. The fix is present in the latest PSXE 2017 Update 1 also.
@Jim – The results the OP noted as expected appear to be correct but let me know if something is being overlooked.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page