Commit 22a3d186 authored by Kenneth Moreland's avatar Kenneth Moreland
Browse files

Fix issues with unused variables

parent 819eaf0e
...@@ -2241,8 +2241,6 @@ void icetDecompressSubImageCorrectBackground( ...@@ -2241,8 +2241,6 @@ void icetDecompressSubImageCorrectBackground(
IceTImage image) IceTImage image)
{ {
IceTBoolean need_correction; IceTBoolean need_correction;
const IceTFloat *background_color;
const IceTUByte *background_color_word;
icetGetBooleanv(ICET_NEED_BACKGROUND_CORRECTION, &need_correction); icetGetBooleanv(ICET_NEED_BACKGROUND_CORRECTION, &need_correction);
if (!need_correction) { if (!need_correction) {
...@@ -2253,10 +2251,6 @@ void icetDecompressSubImageCorrectBackground( ...@@ -2253,10 +2251,6 @@ void icetDecompressSubImageCorrectBackground(
ICET_TEST_IMAGE_HEADER(image); ICET_TEST_IMAGE_HEADER(image);
ICET_TEST_SPARSE_IMAGE_HEADER(compressed_image); ICET_TEST_SPARSE_IMAGE_HEADER(compressed_image);
background_color = icetUnsafeStateGetFloat(ICET_TRUE_BACKGROUND_COLOR);
background_color_word =
(IceTUByte*)icetUnsafeStateGetInteger(ICET_TRUE_BACKGROUND_COLOR_WORD);
#define INPUT_SPARSE_IMAGE compressed_image #define INPUT_SPARSE_IMAGE compressed_image
#define OUTPUT_IMAGE image #define OUTPUT_IMAGE image
#define TIME_DECOMPRESSION #define TIME_DECOMPRESSION
......
...@@ -438,9 +438,11 @@ static radixkPartnerInfo *radixkGetPartners(const radixkRoundInfo *round_info, ...@@ -438,9 +438,11 @@ static radixkPartnerInfo *radixkGetPartners(const radixkRoundInfo *round_info,
= icetSparseImageSplitPartitionNumPixels(start_size, = icetSparseImageSplitPartitionNumPixels(start_size,
current_k, current_k,
remaining_partitions); remaining_partitions);
/* Always send when splitting. */
sending_data = ICET_TRUE; sending_data = ICET_TRUE;
} else { } else {
partition_num_pixels = start_size; partition_num_pixels = start_size;
/* Not splitting. Only send if receiving. */
sending_data = !receiving_data; sending_data = !receiving_data;
} }
sparse_image_size = icetSparseImageBufferSize(partition_num_pixels, 1); sparse_image_size = icetSparseImageBufferSize(partition_num_pixels, 1);
...@@ -450,8 +452,7 @@ static radixkPartnerInfo *radixkGetPartners(const radixkRoundInfo *round_info, ...@@ -450,8 +452,7 @@ static radixkPartnerInfo *radixkGetPartners(const radixkRoundInfo *round_info,
} else { } else {
recv_buf_pool = NULL; recv_buf_pool = NULL;
} }
if (round_info->split) { if (sending_data) {
/* Only need send buff when splitting, always need when splitting. */
send_buf_pool = icetGetStateBuffer(RADIXK_SEND_BUFFER, send_buf_pool = icetGetStateBuffer(RADIXK_SEND_BUFFER,
sparse_image_size * current_k); sparse_image_size * current_k);
} else { } else {
...@@ -476,8 +477,7 @@ static radixkPartnerInfo *radixkGetPartners(const radixkRoundInfo *round_info, ...@@ -476,8 +477,7 @@ static radixkPartnerInfo *radixkGetPartners(const radixkRoundInfo *round_info,
p->receiveBuffer = NULL; p->receiveBuffer = NULL;
} }
if (round_info->split) { if (sending_data) {
/* Only need send buff when splitting, always need when splitting.*/
send_buffer = ((IceTByte*)send_buf_pool + i*sparse_image_size); send_buffer = ((IceTByte*)send_buf_pool + i*sparse_image_size);
p->sendImage = icetSparseImageAssignBuffer(send_buffer, p->sendImage = icetSparseImageAssignBuffer(send_buffer,
partition_num_pixels, 1); partition_num_pixels, 1);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment