Research Article

Scalable Parallel Distributed Coprocessor System for Graph Searching Problems with Massive Data

Algorithm 1

Parallel 1-D BFS algorithm.
Input: , , (source vertex)
Output: parent.
(1) for    do
(2) visit
(3) parent
(4) frontier
(5) next
(6) frontier
(7) level = 0
(8) end = 0
(9) while do
(10) end = 1
(11) if    then
(12) for   do
(13) if    then
(14) for    do
(15) if    then
(16) visit
(17) next
(18) parent
(19) end = 0
(20) else
(21) for    do
(22) if  visit   then
(23) for    do
(24) if    then
(25) visit
(26) next
(27) parent
(28) end = 0
(29) BREAK
(30) BARRIER
(31) for    do
(32) frontier = next
(33) next
(34) level = level + 1
(35)