Tuesday, June 24, 2025

11 Hard Truths from 19 Years in the Indian Software Industry

After spending nearly two decades in the software industry in India, I’ve seen patterns repeat themselves. I’ve witnessed careers rise—and stall—for reasons that rarely get talked about openly. This post isn’t just advice. These are reflections shaped by long hours, countless transitions, and deep observation of both successes and failures around me.

If you’re a software engineer—or aspiring to be one—these are for you.


1. Engineering Isn’t Easy—It’s a Daily Battle

If you believe the life of a software engineer is easy—beware! Every day is a fight to stay relevant, solve complex problems, and survive in an oversaturated market. India has an enormous talent pool, and competition is relentless.


2. High Salary Without Core Tech? A Warning Sign

Earning over ₹25 LPA in 2025 sounds great—but if your work revolves only around tools, scripting, or glue code (not real engineering or systems-level work), you might be walking on thin ice. In 10 years, your employability could take a hit. Focus on mastering core technology—not just tools.


3. Money Over Learning? It Doesn’t Scale

If your priority is the paycheck instead of deepening your technical knowledge—rethink your path. Long-term compensation and career stability come from technical depth and skill—not the other way around. Learn first, earn later.


4. Rushing into Management? Not Always a Win

Getting promoted quickly might feel rewarding, but early managerial roles without a solid tech foundation can backfire. You’ll eventually feel the gap. Becoming a hands-on engineering manager is one of the hardest roles—and it demands real experience, not just titles.


5. Stop Comparing. Start Investing—in Yourself

Promotion timelines and growth will vary. Comparing yourself with colleagues leads nowhere. Instead, focus on building your own skills, staying in roles long enough to grow confidence, and evolving at your own pace. 


6. No Weekend Learning? You’re Falling Behind

If you’re not using at least one weekend day to explore new tech, trends, or tools—you’re slowly becoming obsolete. One day of deep learning can make a long-term difference in staying competitive.


7. Too Many Job Switches? It Shows

If you’ve changed jobs more than 5 times in your first 10 years—think again. Quick jumps may get you short-term hikes, but real expertise comes from sticking around long enough to see projects succeed, fail, and evolve. Give companies 3–5 years if you want sustainable growth.


8. Surrounded by Smart People? You’re Lucky

If your peers are smarter than you, consider yourself lucky. Don't compete—learn. This is the fastest way to grow. The right team can transform your mindset and capabilities.


9. Overseas Assignments? Embrace the Grind

Working abroad in top MNC labs or client locations is a privilege. Yes, the workload might be intense. But don't complain—this is the phase where you grow exponentially. Soak it in.


10. Communication Skills Matter—More Than You Think

If you’re 3+ years into your career, it’s time to take your oral and written communication seriously. Clear, confident Business English is a game-changer—especially in product discussions, global teams, and leadership roles.


11. Just Starting Out? Read, Listen, Learn

If you’re new to the industry—pause and absorb. Learn from senior engineers, read about system design, understand the tech landscape, and walk carefully. Don’t rush. The right start can make all the difference.


Final Thought: Let Engineering Be Your Anchor

Titles, pay, companies—they’ll all change. What remains with you is your engineering skill. So focus there. Everything else will follow.

All the best on your journey. Keep building. Keep learning.


Friday, June 20, 2025

How MMU and Cache Work Together ?


  1. MMU Translates Virtual Address → Physical Address

    • Every memory access from the CPU (in virtual address space) goes through the MMU.

    • It uses page tables to resolve Virtual Address (VA) → Physical Address (PA).

  2. MMU Provides Memory Attributes

    • In addition to translation, the MMU tells the CPU:

      • Is this region cacheable?

      • Should it be write-back, write-through, or non-cacheable?

      • Is it device memory or normal memory?

  3. Cache Uses MMU Info to Decide Behavior

    • If a region is cacheable, cache stores/fetches data for that region.

    • If non-cacheable, all accesses go directly to RAM (or MMIO).

    • MMU attributes control whether cache is used at all.



Example Flow (ARM Cortex-A CPU):

Load [VA = 0xFFFF0000] ↓ MMU: - Translates to PA = 0x10000000 - Checks page tables → memory type = normal, inner-cacheable, write-back ↓ Cache: - Checks if PA = 0x10000000 is in L1/L2 - If hit → return cached data - If miss → fetch from RAM, store in cache











This is why bootloaders and OS kernels carefully configure MMU
and cache together.




Sunday, June 8, 2025

Three important bitwise operations in embedded systems

Setting the Nth bit in the register R via the assignment R |= (1 << N): The new value of the register R will contain the result of the bitwise OR operation between its original value and a bitmask containing all zeros, except the bit corresponding to the value we want to set, which is set to the value one.

Clearing (resetting) the Nth bit in the register R via the assignment R &= ~(1 << N): The new value of the register is the result of a bitwise AND operation between its original value and a bitmask containing all ones, except the bit in the position we want to clear, which is set to the value zero.

Checking whether the Nth bit of the register R is set or cleared, via the condition (R & (1 << N) == (1 << N)): Returns true only if the Nth bit of the register is set.

Thursday, June 5, 2025

C programming - Set n bits from pth position of an integer

int bit_array[32];

void show_bits(int val);

void set_p_n_bits(int val, int p, int n);

int main()

{

    int a,p,n;

    printf("enter a number in hex\n");

    scanf("%x", &a);

    printf("enter a pth position\n");

    scanf("%x", &p);

    printf("enter number of bits\n");

    scanf("%x", &n);

    printf("\nafter setting %d bits from %dth position\n",n,p);

    set_p_n_bits(a,p,n);

    return 0;

}


void show_bits(int val)

{  

     int i;

     for(i=0;i<32;i++)

    {

        bit_array[31-i] = (val & 1);

       val = val >> 1;

   }   

   for(i=0;i<32;i++)

     printf("%d",bit_array[i]);

}

//create mask

//111111111111111111

//000011111111111111 --> 4 shifts

//111100000000000000  --> negation

//000000001111000000  ---> shift 31-p

//if p = 10

//   n = 4

//pth bit

//n is number of bits to be set.

void set_p_n_bits(int val, int p, int n)

{

     int mask = (~(0xffffffff >> n) >> (31-p));

     printf("val is %x = ",val);

     show_bits(val);

     printf("\nmask is ");

     show_bits(mask);

     val = val | mask;

     printf("\nmodified val is %x = ",val);

    show_bits(val);

    return;